precip.dep | R Documentation |
Calculate the cumulative precipitation departure (CPD) for a station with a given precipitation normal.
precip.dep(x, norm, var = "precip")
x |
a seasonal |
norm |
a |
var |
a common seasonal variable found in |
This function is useful for looking at the behaviour of a precipitation time-series in relation to its precipitation normal over an extended period of time. This is especially useful for identifying changes in precipitation, and is useful for relating to groundwater recharge patterns.
Returns a data.frame
similar to x
, but contains the
departures in the dep
column.
The selection of fun
in precip.norm
, such as
using mean
or median
, will affect
the result of this function; width
has only a minor effect.
Periods with missing (NA
) values in var
of x
will
have a flat departure, neither increasing nor decreasing.
Mike Toews
precip.norm
data(mscstn) data(mscdata) dat <- mksub(mscdata, id=1108447) dat.ss <- seas.sum(dat) dat.dep <- precip.dep(dat,precip.norm(dat.ss, fun="mean")) plot(dep ~ date, dat.dep, type="l", main="CPD from mean normals") dat.dep <- precip.dep(dat, precip.norm(dat.ss, fun="median")) plot(dep ~ date, dat.dep, type="l", main="CPD from median normals")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.