Hi, You can try this: x<-1:15 y<--8:6 plot(x, y, type ="o", xlab="Panelist", ylab="T value",lwd=1.5,axes=FALSE) axis(1,at=c(0,2,4,6,8,10,12,14,16)) axis(2,at=c(-8,-6,-4,-2,0,2,4,6,8)) A.K.
________________________________ From: Stefanie Wind <wind.stefa...@gmail.com> To: arun <smartpink...@yahoo.com> Sent: Friday, July 20, 2012 11:42 PM Subject: Re: [R] Control y axis Thanks! Do you know how I could get the values -8:8 to print on the y axis? On Fri, Jul 20, 2012 at 9:06 PM, arun <smartpink...@yahoo.com> wrote: Hi, > >The bracket after lty=1 should be replaced with comma (,). > x<-1:15 > y<--8:6 > plot(x, y, type ="o", xlab="Panelist", ylab="T >value",lwd=1.5,lty=1,xlim=range(1:14),ylim=range(-8:8),las=1) > >A.K. > > > > >----- Original Message ----- >From: stefaniewind <wind.stefa...@gmail.com> >To: r-help@r-project.org >Cc: >Sent: Friday, July 20, 2012 3:29 PM >Subject: [R] Control y axis > >I can't get the y axis to extend the full range that I need, which is -8 to 8 > >Here's my code. I tried using ylim, but it's still truncating at the >extremes in my data. > >plot(x, y, type ="o", xlab="Panelist", ylab="T value",lwd=1.5,lty=1) >xlim=range(1:14),ylim=range(-8:8), las=1) > > >Any suggestions? > >Thanks! > > > >-- >View this message in context: >http://r.789695.n4.nabble.com/Control-y-axis-tp4637266.html >Sent from the R help mailing list archive at Nabble.com. > >______________________________________________ >R-help@r-project.org mailing list >https://stat.ethz.ch/mailman/listinfo/r-help >PLEASE do read the posting guide http://www.R-project.org/posting-guide.html >and provide commented, minimal, self-contained, reproducible code. > > ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.