Description Usage Arguments Details Value Author(s) See Also Examples
Extracts residuals (unstandardized, standardized, studentized, or jackknife) from uRegress
objects.
1 | uResiduals(object, type="", version=FALSE)
|
object |
an object of class |
type |
denotes the type of residuals to return. Default value is |
version |
if |
Relies on functionality from the stats
package to return residuals from the uRegress
object. "studentized"
residuals are computed as internally studentized residuals, while "jackknife"
computes the externally studentized residuals.
Returns the type of residuals requested.
Scott S. Emerson, M.D., Ph.D., Andrew J. Spieker, Brian D. Williamson
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | # Load required libraries
library(survival)
# Reading in a dataset
mri <- read.table("http://www.emersonstatistics.com/datasets/mri.txt",header=TRUE)
# Create a uRegress object, regressing ldl on age
ldlReg <- regress("mean", age~ldl, data=mri)
# Get the studentized residuals
uResiduals(ldlReg, "studentized")
# Get the jackknifed residuals
uResiduals(ldlReg, "jackknife")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.