-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathaxis.Rd
More file actions
52 lines (47 loc) · 1.45 KB
/
axis.Rd
File metadata and controls
52 lines (47 loc) · 1.45 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
% Generated by roxygen2 (4.1.1): do not edit by hand
% Please edit documentation in R/axis.R
\name{axis}
\alias{axis}
\title{gsplot axis}
\usage{
axis(object, ...)
}
\arguments{
\item{object}{gsplot object}
\item{\dots}{Further graphical parameters may also be supplied as arguments. See 'Details'.}
}
\description{
Formats axes for the plotting region. See \code{\link[graphics]{axis}} for more details.
}
\details{
Additional graphical parameter inputs:
\itemize{
\item{\code{side}} {integer indicating the bottom(1), left(2), top(3), or right(4) side of the plot to draw the axis}
\item{\code{labels}} {logical value indicating whether numerical values are shown at the tickmarks, or a character vector of labels for each tickmark}
}
}
\examples{
gs <- gsplot() \%>\%
points(x=1:5, y=1:5, legend.name="Stuff") \%>\%
lines(2:6, y=2:6, ylim=c(0,10)) \%>\%
axis(side=c(3,4),labels=FALSE) \%>\%
legend("topright")
gs
gs <- gsplot() \%>\%
points(y=c(3,1,2), x=1:3, xlim=c(0,NA),ylim=c(0,NA)) \%>\%
axis(side=c(4), labels=FALSE) \%>\%
axis(side=c(1,3), n.minor=4, labels=FALSE)
gs
gs <- gsplot() \%>\%
points(1:10, 1:10) \%>\%
axis(1, at = seq(0,10,by=0.1),labels=FALSE, tcl=0.15)
gs
gs <- gsplot() \%>\%
points(1:5, c(1,10,100,1000,10000), log="y", las=1) \%>\%
axis(side=c(2,4), labels=FALSE, n.minor=4)
gs
gs <- gsplot() \%>\%
lines(1:5, c(1,10,100,1000,10000), log="y", axes=FALSE) \%>\%
axis(side=c(2,4), labels=FALSE, n.minor=4)
gs
}