Skip to contents

Formula: DFBETAS_ij = (beta_j - beta_j(-i)) / (s_(i) sqrt((X'X)^-1_jj))

Usage

Dfbetb(y, X, intercept = TRUE)

Arguments

y

Response vector, length n.

X

Design matrix with n rows.

intercept

Whether to prepend a column of ones.

Value

List with estimate (max |DFBETAS|), dfbetas, threshold, n_influential, n, p, method.

Details

The deletion update beta - beta(-i) = (X'X)^-1 x_i e_i / (1 - h_ii) avoids refitting n times. Cut-off 2/sqrt(n).

References

Belsley, Kuh & Welsch (1980), Regression Diagnostics, Wiley, ch. 2.

Examples

V <- c(1, 2, 3, 4, 5, 6, 7, 8)
Dfbetb(V, V)
#> $estimate
#> [1] 0
#> 
#> $dfbetas
#>      [,1] [,2]
#> [1,]  NaN  NaN
#> [2,]  NaN  NaN
#> [3,]  NaN  NaN
#> [4,]  NaN  NaN
#> [5,]  NaN  NaN
#> [6,]  NaN  NaN
#> [7,]  NaN  NaN
#> [8,]  NaN  NaN
#> 
#> $threshold
#> [1] 0.7071068
#> 
#> $n_influential
#> [1] 0
#> 
#> $n
#> [1] 8
#> 
#> $p
#> [1] 2
#> 
#> $method
#> [1] "DFBETAS scaled change in coefficient when obs i deleted"
#> 
#> attr(,"class")
#> [1] "morie_rich_result" "list"