surrogate: Surrogate Response

Description Usage Arguments Value Note References

View source: R/surrogate.R


Simulate surrogate response values for cumulative link regression models using the latent method described in Liu and Zhang (2017).


surrogate(object, method = c("latent", "jitter"),
  jitter.scale = c("probability", "response"), nsim = 1L, ...)



An object of class clm, glm (jittering only), lrm, orm, polr, vgam (jittering only), or vglm.


Character string specifying the type of surrogate to use; for details, see Liu and Zhang (2017). For cumulative link models, the latent variable method is used. For binary GLMs, the jittering approach is employed. (Currently ignored.)


Character string specifying the scale on which to perform the jittering. Should be one of "probability" or "response". (Currently ignored for cumulative link models.)


Integer specifying the number of bootstrap replicates to use. Default is 1L meaning no bootstrap samples.


Additional optional arguments. (Currently ignored.)


A numeric vector of class c("numeric", "surrogate") containing the simulated surrogate response values. Additionally, if nsim > 1, then the result will contain the attributes:


A matrix with nsim columns, one for each bootstrap replicate of the surrogate values. Note, these are random and do not correspond to the original ordering of the data;

A matrix with nsim columns. Each column contains the observation number each surrogate value corresponds to in boot.reps. (This is used for plotting purposes.)


Surrogate response values require sampling from a continuous distribution; consequently, the result will be different with every call to surrogate. The internal functions used for sampling from truncated distributions are based on modified versions of rtrunc and qtrunc.


Liu, Dungang and Zhang, Heping. Residuals and Diagnostics for Ordinal Regression Models: A Surrogate Approach. Journal of the American Statistical Association (accepted). URL

Nadarajah, Saralees and Kotz, Samuel. R Programs for Truncated Distributions. Journal of Statistical Software, Code Snippet, 16(2), 1-8, 2006. URL

AFIT-R/sure documentation built on Nov. 21, 2017, 9:23 a.m.