Laurent,

On Sun, Nov 29, 2009 at 4:13 AM, Laurent Gautier <lgaut...@gmail.com> wrote:
>
> That's more an issue with ggplot2 than with rpy2.
> What I meant earlier is the following:
>
> pp += ggplot2.geom_line(ggplot2.aes_string(x='z',y='dens'),
>                        data=datafline)
>
>
> It is working here (rpy2-2.1dev -- note: your code revealed a bug with
> rpy2.robjects, so you might need a very recent update from the repository).

That seem to have been the issue. By upgrading to the most recent
update in the repository, I have been able to plot both the histogram
and the line, each from a different dataset. As a side note, it
appears that ggplot2.aes_string is now ggplot2.aes, which is the way
it is in R.

Next problem: Because I included the option y='..density..' in my
histogram aes, my plot now has ..density.. as its x label. This
doesn't happen in R. I thought I could rectify this by adding the line
pp=pp+ggplot2.opts(xlab="z"), but that doesn't seem to work. If I
remove the option y='..density..' from my histogram aes, I get z as my
x label, but I still cannot change it using the options (e.g.
pp=pp+ggplot2.opts(xlab="z position") has no effect). Any thoughts?

Faisal

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
rpy-list mailing list
rpy-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rpy-list

Reply via email to