visualization of linear models
play

Visualization of Linear Models Correlation and Regression Possums - PowerPoint PPT Presentation

CORRELATION AND REGRESSION Visualization of Linear Models Correlation and Regression Possums > ggplot(data = possum, aes(y = totalL, x = tailL)) + geom_point() Correlation and Regression Through the origin > ggplot(data = possum,


  1. CORRELATION AND REGRESSION Visualization of Linear Models

  2. Correlation and Regression Possums > ggplot(data = possum, aes(y = totalL, x = tailL)) + geom_point()

  3. Correlation and Regression Through the origin > ggplot(data = possum, aes(y = totalL, x = tailL)) + geom_point() + geom_abline(intercept = 0, slope = 2.5)

  4. Correlation and Regression Through the origin, be � er fit > ggplot(data = possum, aes(y = totalL, x = tailL)) + geom_point() + geom_abline(intercept = 0, slope = 1.7)

  5. Correlation and Regression Not through the origin > ggplot(data = possum, aes(y = totalL, x = tailL)) + geom_point() + geom_abline(intercept = 40, slope = 1.3)

  6. Correlation and Regression The "best" fit line > ggplot(data = possum, aes(y = totalL, x = tailL)) + geom_point() + geom_smooth(method = "lm")

  7. Correlation and Regression Ignore standard errors > ggplot(data = possum, aes(y = totalL, x = tailL)) + geom_point() + geom_smooth(method = "lm", se = FALSE)

  8. CORRELATION AND REGRESSION Let’s practice!

  9. CORRELATION AND REGRESSION Understanding the linear model

  10. Correlation and Regression Generic statistical model response = f(explanatory) + noise

  11. Correlation and Regression Generic linear model response = intercept + (slope * explanatory) + noise

  12. Correlation and Regression Regression model

  13. Correlation and Regression Fi � ed values

  14. Correlation and Regression Residuals

  15. Correlation and Regression Fi � ing procedure

  16. Correlation and Regression Least squares ● Easy, deterministic, unique solution ● Residuals sum to zero ● Line must pass through ● Other criteria exist—just not in this course

  17. Correlation and Regression Key concepts ● Y-hat is expected value given corresponding X ● Beta-hats are estimates of true, unknown betas ● Residuals (e's) are estimates of true, unknown epsilons ● "Error" may be misleading term—be � er: noise

  18. CORRELATION AND REGRESSION Let’s practice!

  19. CORRELATION AND REGRESSION Regression vs. regression to the mean

  20. Correlation and Regression Heredity ● Galton's "regression to the mean" ● Thought experiment: consider the heights of the children of NBA players

  21. Correlation and Regression Galton's data

  22. Correlation and Regression Regression modeling ● "Regression": techniques for modeling a quantitative response ● Types of regression models: ● Least squares ● Weighted ● Generalized ● Nonparametric ● Ridge ● Bayesian ● …

  23. CORRELATION AND REGRESSION Let’s practice!

Recommend


More recommend