plotLA {scape}R Documentation

Plot Length at Age

Description

Plot scape model fit to length-at-age data.

Usage

plotLA(model, together=FALSE, sex=NULL, axes=TRUE, same.limits=TRUE,
       between=list(x=axes,y=axes), ylim=NULL, bands=1, main="",
       xlab="", ylab="", cex.main=1.2, cex.lab=1, cex.strip=0.8,
       cex.axis=0.8, las=1, tck=0, tick.number=5, lty.grid=3,
       col.grid="grey", pch=16, cex.points=0.5, col.points="black",
       lty.lines=1, lwd.lines=4, col.lines=c("red","blue"),
       lty.bands=2*(!together), lwd.bands=1, col.bands="black",
       plot=TRUE, ...)

Arguments

model fitted scape model containing element LA.
together whether both sexes should be plotted in one panel.
sex string indicating which sex should be plotted (both by default).
axes whether axis values should be plotted.
same.limits whether panels should have same y-axis limits.
between list with x and y indicating panel spacing.
ylim vector with lower and upper y-axis limits.
bands extent of error bands relative to standard error.
main main title.
xlab x-axis label.
ylab y-axis label.
cex.main size of main title.
cex.lab size of axis labels.
cex.strip size of strip labels.
cex.axis size of tick labels.
las orientation of tick labels: 0=parallel, 1=horizontal, 2=perpendicular, 3=vertical.
tck tick mark length.
tick.number number of tick marks.
lty.grid line type of gridlines.
col.grid colour of gridlines.
pch symbol for points, possibly a vector where element 2 refers to males.
cex.points size of points, possibly a vector where element 2 refers to males.
col.points colour of points, possibly a vector where element 2 refers to males.
lty.lines line type of main lines, possibly a vector where element 2 refers to males.
lwd.lines line width of main lines, possibly a vector where element 2 refers to males.
col.lines colour of main lines, possibly a vector where element 2 refers to males.
lty.bands line type of error bands.
lwd.bands line width of error bands.
col.bands colour of error bands, possibly a vector where element 2 refers to males.
plot whether to draw plot.
... passed to xyplot and panel.superpose.2.

Value

When plot=TRUE, a trellis plot is drawn and a data frame is returned, containing the data used for plotting. When plot=FALSE, a trellis object is returned.

Note

This function tries to draw the plot on a trellis device with a white background.

The Args function from the gdata package is recommended for reviewing the arguments, instead of args.

Author(s)

Arni Magnusson arnima@u.washington.edu.

See Also

Lattice, xyplot, panel.xyplot, panel.superpose.

scape-package gives an overview of the package.

Examples

plotLA(x.oreo, xlab="Age", ylab="Length (cm)")

mykey <- list(text=list(lab=c("Female","Male")), space="right",
              lines=list(lwd=4,col=c("red","blue")))
plotLA(x.oreo, together=TRUE, xlab="Age", ylab="Length (cm)", pch=NA,
       key=mykey)

mykey <- list(text=list(lab=c("Female","Male")), space="right",
              points=list(pch=16,cex=0.5,col=c("red","blue")))
plotLA(x.oreo, together=TRUE, xlab="Age", ylab="Length (cm)",
       col.points=c("red","blue"), lty.lines=0, key=mykey)

[Package scape version 1.0-8 Index]