[R] doubt about graphics

Spencer Graves spencer.graves at pdf.com
Mon Jul 21 17:27:51 CEST 2003


x <- c(1:11)
y <- seq(245,445,20)

plot(x,y, axes=F, ylim=c(240, 480))
axis(1)
axis(2, at=seq(240, 480, 40))

Worked for me on R 1.7.1 and S-Plus 6.1 under Win2000.

hope this helps.  spencer graves

Ronaldo Reis Jr. wrote:
> Hi,
> 
> I have an data like this
> 
> x <- c(1:11)
> y <- seq(245,445,20)
> 
> I make a plot
> 
> plot(x,y)
> 
> The first y value in y axis is 250 and the last y valeu is 450, the spacing 
> between values are 50, so the y values showed are: 250, 300, 350, 400, 450
> 
> I need that values in y axis are: 240, 280, 320, 360, 400, 440, 480.
> 
> I try
> 
> plot(x,y,yaxp=c(240,480,6))
> 
> dont work
> 
> I try
> 
> plot(x,y,yaxp=c(240,480,6),ylim=range(240,480))
> 
> dont work too.
> 
> How I make this control?
> 
> Thanks
> Ronaldo
>




More information about the R-help mailing list