Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- data("mtcars")
- str(mtcars)
- m1<-lm(hp ~ disp, data = mtcars)
- m2<-lm(hp ~ disp + wt, data = mtcars)
- library(texreg)
- screenreg(list(m1, m2))
- ===================================
- Model 1 Model 2
- -----------------------------------
- (Intercept) 45.73 ** 68.84 *
- (16.13) (31.80)
- disp 0.44 *** 0.54 ***
- (0.06) (0.14)
- wt -14.45
- (17.10)
- -----------------------------------
- R^2 0.63 0.63
- Adj. R^2 0.61 0.61
- Num. obs. 32 32
- RMSE 42.65 42.85
- ===================================
- *** p < 0.001, ** p < 0.01, * p < 0.05
- library(stargazer)
- l1 <- lm(mpg ~ hp + drat, data=mtcars)
- l2 <- lm(mpg ~ disp + hp, data=mtcars)
- stargazer(l1, l2, title= "Regression comparision", type="html")
Add Comment
Please, Sign In to add comment