Skip to contents

theta = (X^T X)^-1 X^T y, solved not inverted, with the rank and condition number reported.

Usage

morie_geron_ch4_normal_equation(X, y)

Arguments

X, y

Design and targets, m >= n.

Value

List with theta, cost, residuals, rank, condition_number.

Examples

morie_geron_ch4_normal_equation(X = 5L, y = 5L)
#> $theta
#> [1] 1
#> 
#> $cost
#> [1] 0
#> 
#> $residuals
#> [1] 0
#> 
#> $rank
#> [1] 1
#> 
#> $condition_number
#> [1] 1
#> 
#> $estimate
#> [1] 1
#> 
#> $n
#> [1] 1
#>