Linear Regression — OLS (continuous y + predictors)
VerifiedAdvanced & specialized
Run this test straight away on a free built-in teaching dataset — no data of your own needed — or bring your own. Either opens the guided workspace: variable setup, assumption diagnostics, results with effect sizes and confidence intervals, figures, and APA-ready reporting.
Loading teaching datasets…
Or use your own dataset
Loading your datasets…
Models a continuous outcome as a linear combination of one or more predictors (continuous or dummy-coded categorical).
Reports per-predictor coefficients (β with SE, t, p, 95% CI, standardised β), overall model fit (R², adjusted R², F, AIC, BIC), Type-III ANOVA, and a full residual / influence diagnostic panel (Breusch-Pagan heteroscedasticity, Durbin-Watson autocorrelation, Cook's D / leverage / studentised residual outliers). The engine auto-switches the inferential basis to HC3 robust standard errors when Breusch-Pagan rejects.
Worked example
How well does study time predict exam score, and by how much?
Exam score (0–100) was regressed on weekly study hours for 80 students.
Study time significantly predicted exam score: each extra hour added ~2.3 points (b = 2.29, β = .64), t(78) = 7.45, p < .001; the model explained 42% of the variance, R² = .42.
A simple linear regression showed weekly study time significantly predicted exam score, b = 2.29, 95% CI [1.68, 2.90], β = .64, t(78) = 7.45, p < .001, R² = .42.
Try it yourself: Load this ready-made sample and follow the run above.
When to use it
- Continuous outcome + k predictors on the same casesPredicting exam score from hours studied + prior GPA + sleep hours in 200 students.
- RCT or experimental design with continuous outcome + covariatesRCT of new drug at 3 doses (placebo / low / high) with baseline severity as covariate.
When NOT to — use instead
- Binary / categorical outcomeOLS on binary outcomes violates assumptions (heteroscedasticity built-in, predictions outside [0,1]). → Binomial Logistic Regression \u2014 odds ratios + ROC AUC + classification
- Count outcome (Poisson-distributed)Counts have variance ≈ mean — OLS is inefficient. → Poisson Regression \u2014 IRR for count outcomes (auto-flags overdispersion)
- Clustered / nested observationsOLS assumes independence. → Linear Mixed Effects (LMM) \u2014 clustered / repeated data (ICC, BLUPs)
- Time-series / autocorrelated outcomeOLS assumes independent residuals. → ARIMA
Hypotheses
Parameter tested: vector of population coefficients β
Assumptions (and what to do if they fail)
Check: Shapiro-Wilk p-value on residuals.
If violated: Non-normal residuals affect p-values and CI for small-n models.
Check: Breusch-Pagan p-value.
If violated: Heteroscedasticity inflates SEs — CI and p-values become unreliable.
Check: Durbin-Watson statistic in [1.5, 2.5] is OK.
If violated: Autocorrelated residuals bias SEs and can hide trends.
Check: Max Cook's D reported.
If violated: An influential case can dominate slope estimates — report fit with and without.
Check: Max VIF across predictors.
If violated: High VIF inflates coefficient SEs — some βs look non-significant when the underlying relationship is real, just shared with another predictor.
Ready to run a Linear Regression — OLS (continuous y + predictors) on your own data?
Guided setup, automatic assumption checks, effect sizes, figures and an APA write-up.
Run this test →