Linear Regression Calculator
Linear Regression Calculator lets you least-squares regression fits y = slope × x + intercept. Enter your own values or load the worked example.
- Copy or download the computed result
- Adjust x values
- See the processing method and limits
Method and calculation
Least-squares regression fits y = slope × x + intercept.
Inputs and settings
Linear Regression Calculator accepts X values; Y values.
Worked example
Linear Regression Calculator example — X values: "1,2,3,4"; Y values: "2,4,5,8". Computed output: { "slope": 1.9, "intercept": 0 }
Output and limitations
Linear Regression Calculator: Use finite inputs. Results use double-precision arithmetic.
Technical references: JavaScript Unicode normalization
Linear Regression Calculator FAQs
Linear Regression Calculator applies the following rule to your input: Least-squares regression fits y = slope × x + intercept. The worked example on this page uses the same processor as the result button.
Linear Regression Calculator has these boundaries: Use finite inputs. Results use double-precision arithmetic. Start by checking the x values field against the units or format shown.
Linear Regression Calculator provides this sample: { "slope": 1.9, "intercept": 0 }. Use the sample button to reproduce it, then replace the inputs with your own values.