Re: [R] Adding a line to barchart

2013-01-23 Thread PIKAL Petr
Hi > -Original Message- > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > project.org] On Behalf Of Jonathan Greenberg > Sent: Wednesday, January 23, 2013 5:44 PM > To: r-help > Subject: Re: [R] Adding a line to barchart > > Great! This really help

Re: [R] Adding a line to barchart

2013-01-23 Thread S Ellison
> > I need a quick help with the following graph (I'm a lattice newbie): > > > > require("lattice") > > npp=1:5 > > names(npp)=c("A","B","C","D","E") > > barchart(npp,origin=0,box.width=1) > > > > # What I want to do, is add a single vertical line > positioned at x = 2 > > that lays over the

Re: [R] Adding a line to barchart

2013-01-23 Thread Jonathan Greenberg
t; > Petr > > > -Original Message- > > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > > project.org] On Behalf Of Jonathan Greenberg > > Sent: Tuesday, January 22, 2013 11:42 PM > > To: r-help > > Subject: [R] Adding a line to barchart &

Re: [R] Adding a line to barchart

2013-01-22 Thread PIKAL Petr
ginal Message- > From: r-help-boun...@r-project.org [mailto:r-help-bounces@r- > project.org] On Behalf Of Jonathan Greenberg > Sent: Tuesday, January 22, 2013 11:42 PM > To: r-help > Subject: [R] Adding a line to barchart > > R-helpers: > > I need a quick help with t

Re: [R] Adding a line to barchart

2013-01-22 Thread arun
Hi, May be this helps:  barchart(npp,origin=0,box.width=1,  panel=function(x,y,...){  panel.barchart(x,y,...)  panel.abline(v=2,col.line="red",lty=3)}) A.K. - Original Message - From: Jonathan Greenberg To: r-help Cc: Sent: Tuesday, January 22, 2013 5:41 PM Subject: [R

[R] Adding a line to barchart

2013-01-22 Thread Jonathan Greenberg
R-helpers: I need a quick help with the following graph (I'm a lattice newbie): require("lattice") npp=1:5 names(npp)=c("A","B","C","D","E") barchart(npp,origin=0,box.width=1) # What I want to do, is add a single vertical line positioned at x = 2 that lays over the bars (say, using a dotted line