Re: [R] Adding a vertical line to plot with two overlapping density plots

2012-01-04 Thread David L Carlson
M To: josh rosen Cc: r-help@r-project.org Subject: Re: [R] Adding a vertical line to plot with two overlapping density plots > > thank you very much Petr. Yes, I meant densityplot form lattice. > > The code I gave plots the densities of both x1 and x2 in one panel. > Could

Re: [R] Adding a vertical line to plot with two overlapping density plots

2012-01-04 Thread Petr PIKAL
> > thank you very much Petr. Yes, I meant densityplot form lattice. > > The code I gave plots the densities of both x1 and x2 in one panel. > Could you show me how to integrate the function addline into the code so > that a vertical line v=0 is added? The function is used after you make a

Re: [R] Adding a vertical line to plot with two overlapping density plots

2012-01-04 Thread josh rosen
thank you very much Petr. Yes, I meant densityplot form lattice. The code I gave plots the densities of both x1 and x2 in one panel. Could you show me how to integrate the function addline into the code so that a vertical line v=0 is added? On 4 January 2012 15:55, Petr PIKAL wrote: > Hi > >

Re: [R] Adding a vertical line to plot with two overlapping density plots

2012-01-04 Thread Petr PIKAL
Hi > > Hi, > A simple question I hope. I wish to add a single vertical line to a plot > with several density plots. > Here is a simplified example. > > > thedata <- data.frame(x1=rnorm(100,1,1),x2=rnorm(100,3,1)) #create data > thedata.m<-melt(thedata) > densityplot(~value, thedata.

[R] Adding a vertical line to plot with two overlapping density plots

2012-01-04 Thread josh rosen
Hi, A simple question I hope. I wish to add a single vertical line to a plot with several density plots. Here is a simplified example. thedata <- data.frame(x1=rnorm(100,1,1),x2=rnorm(100,3,1)) #create data thedata.m<-melt(thedata) densityplot(~value, thedata.m, groups=variable,auto.k