plot.seas.sum | R Documentation |
Plots normalized seasonal sums using boxplots.
## S3 method for class 'seas.sum' plot(x, var, norm = "days", year.filter, ylim, start = 1, rep = 0, col = "lightgrey", main, ylab, ...)
x |
a |
var |
name of seasonal variable in |
norm |
a variable to normalize by, either |
year.filter |
use only these years for analysis |
ylim |
either a single value for |
start |
starting bin at left-hand side of plot |
rep |
repeat bins on right-hand side of plot |
col |
colour for boxplot, default is |
main |
title for plot; if it is missing, then it will automatically be generated |
ylab |
y-axis label; if it is missing, then it will automatically be generated |
... |
ignored |
This function is a boxplot interpretation of a seas.sum
object. This is not the same as treating var
as a continuous
variable and using seas.var.plot
, since a seas.sum
object has been smoothed. Daily extreme values are not well
represented here as a result.
The appearance of the boxplots are sensitive to the width
parameter specified in the seas.sum
function on strongly
discontinuous variables. Small bin widths capture the discontinuities
better than wider bins, and changes the skew of the distribution.
For instance, the median will appear to decrease as width
decreases.
Mike Toews
seas.sum
, image.seas.sum
, seas.norm
data(mscdata) par.orig <- par(no.readonly=TRUE) on.exit(par.orig) dat <- mksub(mscdata, id=1108447) dat.ss <- seas.sum(dat) # Normalized by the number of days in each bin plot(dat.ss) # Normalized by the number of active days in each bin plot(dat.ss, norm="active") # Snow, using a different start day, and a better y-axis: dat2.ss <- seas.sum(dat, var="snow", width="mon", start.day=as.Date("2000-08-01")) par(yaxs="i") plot(dat2.ss, var="snow") plot(dat2.ss, var="snow", norm="active")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.