Skip to content

Latest commit

 

History

History
13 lines (11 loc) · 651 Bytes

README.md

File metadata and controls

13 lines (11 loc) · 651 Bytes

LinearRegression

linear-regression-workflow.R

A workflow for processing linear regression
  1. Get correlations
  2. Scatterplot of independent vs. dependent variable
  3. Density plot of variable distributions; check for normal distribution to use linear regression
  4. (Optional) Box plot to visualize outliers
  5. Build linear model
  6. Evaluate linear model: t-stat, p-value, goodness of fit with f-stat & standard error, adjusted r^2, AIC, BIC
  7. Rebuild linear model with training & test sets; measure accuracy via correlation of actual vs predicted values
  8. K-fold cross validation: cross-validate the linear model with k-folds; analyze