rssSplit: Residual sum of squares split

Description Usage Arguments Value Author(s) Examples

View source: R/rssSplit.R

Description

Split residual sum of squares from normal linear regression

Usage

1
rssSplit(fit, df0 = max(1, floor(fit$df/10)), seed = -71407)

Arguments

fit

lm object

df0

degrees of freedom for the smaller of the two residual sums of squares

seed

random seed for constructing the basis vectors of the split

Value

a two-dimensional vector of independent sums of squares

Author(s)

Peter Hoff

Examples

1
2
3
4
5
6
n<-30 ; p<-6 ; sigma2<-1.5 
X<-matrix(rnorm(n*p),n,p) 
y<-X%*%rnorm(6) + sqrt(sigma2)*rnorm(n) 
ss<-rssSplit(lm(y~ -1+X)) 
df<-as.numeric( substring(names(ss),first=3)) 
ss/df

FABInference documentation built on Jan. 9, 2020, 5:08 p.m.