Usage
setupSTdataset(rawobs, covardat, covarnames, trendf,
varnames=list(yraw="lac",date="intended_wednesday",idobs="site_id",idcov="site.id",xcoord="lambert.x",ycoord="lambert.y",long="longitude",lat="latitude"), x.to.km=1000,transform=log,scale=TRUE,mesa=TRUE)
Arguments
rawobs
Data frame with the raw observations. Should have vectors whose
names are identified by the items ``yraw'', ``date'',``idobs'' in
varnames
.
covardat
Data frame with the regression predictors. Should have vectors whose
names are identified by the items ``idcov'', ``xcoord'', ``ycoord'',
``long'', ``lat'' in varnames
.
covarnames
Character vector with the names of variables in
covardat
that should be included in the modeling dataset. If
you are not sure, then just specify all names (i.e.,
``names(covardat)'').
trendf
Matrix or data frame with the time trend, on the
modeling scale. Its format should be compatible with the output of
SVD.smooth
: columns represent the smooth time trends, and the
row names are in the R
varnames
List of character strings denoting the variable names
needed to identify and match the various data components. See
above.
x.to.km
Numeric, conversion factor from the coordinate scale to
km. Defaults to 1000. Set to 1 to ignore.
transform
Function, the transformation link from the scale in
which observations appear in rawobs
, to the modeling
scale. Defaults to log
. scale
Logical: should the covariates in the LUR component be
scaled to each have mean 0 and variance 1? Defaults to TRUE
.
mesa
Logical: should we assume that location ID names follow
the MESA-Air convention? Defaults to TRUE
.