update.survreg_map: Update method for 'survreg_map'

Description Usage Arguments Value


A critical difference between this update method and the typical method for other R objects concerns how centering/scaling of the data is (not) updated. The standardization of variables is important in survreg_map, because priors are placed on the standardized scale. So if updating the data meant re-computing this standardization, the updated vs. original models would effectively have different priors. Instead, for this update method, whether the standardization is recomputed is controlled by the 'reeval_scaling_and_terms' argument. If only data are being updated, this defaults to FALSE, meaning that standardization will *not* be recomputed. This includes both scaling accomplished by code within survreg_map (controlled by the standardize_x argument), as well as scaling accomplished by transformations in the formula, such as stats::scale, stats::poly, splines::ns, and other functions with makepredictcall methods (this is controlled by the predvars argument).


## S3 method for class 'survreg_map'
update(object, formula. = NULL, anc. = NULL,
  reeval_scaling_and_terms = NULL, ..., evaluate = TRUE)



Object of class survreg_map


Passed to update.formula for the main formula argument.


A named list of formulas, each of which are passed to update.formula for the corresponding anc formula.


Should scaling and terms be re-computed with new data? For details on scaling see 'Description'. This also controls whether the 'contrasts' and 'xlevels' arguments are updated. Broadly, the idea is to be cross-validation friendly: for example, if new factor-levels are present in a validation-fold that weren't in the training fold, that's OK because all levels of the factor were remembered from the original model-object.


Slots to update.


If true evaluate the new call else return the call.


If evaluate = TRUE the fitted object, otherwise the updated call.

jwdink/survbayes documentation built on May 4, 2019, 4:23 p.m.