Dear All,
The std. error of the estimated coefficients
obtained by the summary.lm function can be calculated
as:
y=rnorm(20)
x=y+rnorm(20)
fit <- lm(y ~ x)
summary(fit)
sqrt( sum(fit$resid**2)/fit$df.resid *
solve(t(model.matrix(fit))%*%model.matrix(fit)) )
Is posible calculate Std. Error
Hi all,
I want t use a contrasts in adjusted regression (lm()) for a factor with four
levels, compared the coefficients first with second, first with third, ...,
third with fourth.
Someone can help with a contrast matrix to be used. I tried and not yet I
obtained.
Say:
y <- rnorm(50)
x <- cu
2 matches
Mail list logo