Standard Error for bivariable zscore normalized regression
조회 수: 3 (최근 30일)
이전 댓글 표시
Can someone explain why I get exactly same value of satndard error when I use fitlm for two variables x1 and x2 that are zscore normalized?
x=[zscore(x1) zscore(x2)]
fitlm(x,y)
x=0.5519 -1.5191
0.8152 0.9382
-1.4367 0.8976
0.8371 -0.5285
0.0246 0.4234
-1.5218 -1.5667
-0.9986 -0.7207
-0.2226 0.7723
0.9647 0.3990
0.9861 0.9046
y=0.6557
0.0357
0.8491
0.9340
0.6787
0.7577
0.7431
0.3922
0.6555
0.1712
댓글 수: 0
답변 (1개)
Ive J
2021년 9월 11일
And why is it surprising to you?
You can read about how coefficients and their SE are calculated in linear regression. Standardized IVs have 0 mean and variance of 1. One component of SE(β) is inv(X*X'), where X is your design matrix, more precisely:
se = sqrt(model.MSE.*diag(inv(X*X'))); % model: object output of fitlm
So: . We also know IVs have variance of 1, so , so we can simplify this to , which only depdends on IVs length.
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!