Rev 78769 | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed
% File src/library/grid/man/grid.xaxis.Rd% Part of the R package, https://www.R-project.org% Copyright 1995-2020 R Core Team% Distributed under GPL 2 or later\name{grid.xaxis}\alias{grid.xaxis}\alias{xaxisGrob}\title{Draw an X-Axis}\description{These functions create and draw an x-axis.}\usage{grid.xaxis(at = NULL, label = TRUE, main = TRUE,edits = NULL, name = NULL,gp = gpar(), draw = TRUE, vp = NULL)xaxisGrob(at = NULL, label = TRUE, main = TRUE,edits = NULL, name = NULL,gp = gpar(), vp = NULL)}\arguments{\item{at}{A numeric vector of x-value locations for the tick marks.}\item{label}{A logical value indicating whether to draw the labelson the tick marks, or an expression or character vector whichspecify the labels to use. If not logical, must be the samelength as the \code{at} argument.}\item{main}{A logical value indicating whether to draw the axisat the bottom (\code{TRUE}) or at the top (\code{FALSE}) of theviewport.}\item{edits}{A gEdit or gEditList containing edit operationsto apply (to the children of the axis)when the axis is first created and during redrawingwhenever \code{at} is \code{NULL}.}\item{name}{ A character identifier. }\item{gp}{An object of class \code{"gpar"}, typically the outputfrom a call to the function \code{\link{gpar}}. This is basicallya list of graphical parameter settings.}\item{draw}{A logical value indicating whether graphics outputshould be produced.}\item{vp}{A Grid viewport object (or \code{NULL}).}}\details{Both functions create an xaxis grob (a graphical object describing anxaxis), but only \code{grid.xaxis}draws the xaxis (and then only if \code{draw} is \code{TRUE}).}\value{An xaxis grob. \code{grid.xaxis} returns the value invisibly.}\section{Children}{If the \code{at} slot of an xaxis grob is not \code{NULL} thenthe xaxis will have the following children:\describe{\item{major}{ representing the line at the base of thetick marks.}\item{ticks}{representing the tick marks.}\item{labels}{representing the tick labels.}}If the \code{at} slot is \code{NULL} then there are no childrenand ticks are drawn based on the current viewport scale.}\author{Paul Murrell}\seealso{\link{Grid},\code{\link{viewport}},\code{\link{grid.yaxis}}}\keyword{dplot}