Description Usage Arguments Value
View source: R/utility_functions.R
This function takes OLS coefficients from a model including a squared variable as inputs and bias corrects according to the noise matrix, S
1 | betaTildeSq(coef, S, X, N, index_sq)
|
coef |
Vector of OLS coefficients |
S |
Matrix of error terms. Dimensions must be length(coef) x length(coef) |
X |
Design matrix that produced OLS coefficients |
N |
Number of rows in X |
index_sq |
Column index of X covariate that is squared |
Returns a list:
bias_correct |
Vector of bias corrected coefficients |
x_prime_x |
X'X matrix to be used in variance estimation |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.