Enter points, upload data, or paste lists easily. See fitted equation, diagnostics, and residual tables. Download CSV or PDF summaries for sharing anywhere fast.
| x | y |
|---|---|
| 1 | 2.2 |
| 2 | 3.9 |
| 3 | 6.1 |
| 4 | 7.8 |
| 5 | 10.2 |
| 6 | 11.9 |
A simple linear model relates inputs and outputs using: y = a + b·x.
If “through origin” is enabled, the model uses a = 0 and b = Σ(xy) / Σ(x²).
A linear model relies on paired observations, where each x is matched to a measured y. Clean inputs reduce bias and numerical instability. This calculator accepts manual rows, pasted pairs, or uploaded files, then keeps only lines with two valid numbers. When values are large, consistent units and sensible rounding matter because slope is sensitive to scale. If you expect proportional behavior, the origin option can be enabled, but only when theory supports zero output at zero input.
The fitted equation is y = a + b·x. The slope b is estimated from covariance divided by variance, using b = Σ((x−x̄)(y−ȳ)) / Σ((x−x̄)²). The intercept a follows from a = ȳ − b·x̄. These formulas minimize the sum of squared residuals, SSE = Σ(y−ŷ)², producing the best straight line under the least squares criterion. The calculator displays both parameters and the full table of fitted values.
Goodness of fit is summarized with R², MAE, and RMSE. R² compares unexplained variation to total variation via 1 − SSE/SST, where SST = Σ(y−ȳ)². MAE reports the typical absolute miss in output units, while RMSE emphasizes larger errors and reflects residual dispersion. When the dataset is small, avoid overinterpreting a high R²; it can occur with limited x range or influential points.
Residuals should look pattern free when plotted against x. Curvature suggests a nonlinear relationship, and changing spread suggests non-constant variance. With enough degrees of freedom, the calculator estimates residual standard error and standard errors for parameters, then forms confidence intervals using a t critical value at the selected level. Wider intervals indicate weaker evidence for a stable slope or intercept.
Once parameters are fitted, predictions use ŷ = a + b·x for any new x. The single prediction field supports quick checks, while the range settings generate a forecast table for planning and documentation. Export tools create a compact summary file and a detailed file containing residuals and predictions. This reporting workflow helps teams review assumptions, compare scenarios, and keep a transparent audit trail. Use consistent sampling to improve repeatable, comparable insights for stakeholders across projects and time.
The slope is the expected change in y for a one‑unit increase in x. A positive slope indicates growth, while a negative slope indicates decline, assuming other conditions remain similar.
Use it only when zero input must produce zero output by design or physics. Forcing a zero intercept can distort the fit if the true relationship includes an offset.
R² measures fit within the observed x range, not future accuracy. Narrow x variation, outliers, or extrapolation beyond the data can produce unreliable forecasts even with a strong R².
Trends or curves in residuals suggest a missing nonlinear term. Increasing spread suggests changing variance. Both are signals to reconsider the model or transform variables.
Two points define a line, but more points improve stability. For confidence intervals and robust diagnostics, aim for at least five to ten well‑spaced observations.
The summary export contains key parameters and metrics. The full export includes each point, fitted values, residuals, and any prediction range rows, making review and sharing straightforward.
Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.