[R] Plot - specification for grid of x axis
Greg.Snow at imail.org
Tue Feb 2 17:28:53 CET 2010
When you create your plot us the argument xaxt='n'. That will suppress the default axis labels and tick marks. Then use the axis function which lets you specify exactly where you want the tick marks and exactly what you want the labels to be. You can also specify tck=1 as an argument if you want grid lines (see ?par for details).
Hope this helps,
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
greg.snow at imail.org
> -----Original Message-----
> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
> project.org] On Behalf Of Trafim Vanishek
> Sent: Tuesday, February 02, 2010 8:12 AM
> To: r-help at r-project.org
> Subject: [R] Plot - specification for grid of x axis
> Dear all,
> I have a simple question for which I cannot find the answer.
> I need to make an easy plot, but for the x axis I need to be able to
> by myself the division of x axis from x[,1] either every single
> or every 5th, or 10th or 20th
> x <- matrix(data=NA, nrow=100, ncol=2)
> Thanks a lot for your help!!!
> [[alternative HTML version deleted]]
> R-help at r-project.org mailing list
> PLEASE do read the posting guide http://www.R-project.org/posting-
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help