Tour of curve.fit
Fit your data with its uncertainties in x and y.
Paste measurements from a spreadsheet, choose a model, and get every parameter with its uncertainty, a plot with residuals and a one-page report. Free, in any browser, with no install or account.
A 58-second silent tour with on-screen captions, using Pearson's data with York's weights. The chapters below describe each step.
-
Copy x, δx, y and δy from a spreadsheet, or import a CSV file of up to 10,000 rows.
-
Choose Table for δx and δy, and each point is weighted by its uncertainty in both directions.
-
Or type your own equation. curve.fit suggests a matching built-in model.
-
Every parameter comes with its uncertainty, plus reduced χ² and residuals. This fit matches the published Pearson–York result.
-
A one-page PDF with the model, parameters, plot and residuals. Excel and Browser Report too.
Uncertainties done properly
x and y errors supported
Spreadsheet trendlines ignore measurement uncertainty. When you supply δx and δy, curve.fit uses orthogonal distance regression (ODRPACK95), so every point is weighted by its uncertainty in both directions.
- Uncertainties come from a column per point, or from one constant or percentage for the whole dataset.
- Absolute uses your 1σ values as given. Nominal, the default, rescales by √χ²red, the same default as SciPy, lmfit and Origin.
- Evaluate predicts y ± δy at any x, or solves for x from a measured y.
| You supply | curve.fit fits with |
|---|---|
| None | Ordinary least squares in y |
| δy only | Weighted least squares in y |
| δx only | Orthogonal distance regression, exact-y limit |
| δx and δy | Weighted orthogonal distance regression |
Numerical correctness
Checked against published answers
Before every release, an automated suite fits reference datasets with known answers and compares parameters, standard errors and residual sums of squares.
NIST Statistical Reference Datasets. 21 datasets, 4 linear and 17 nonlinear, fitted from 55 certified and published starting points, must match NIST's certified values.
relative tolerance 1 × 10⁻⁶Details, tolerances and references are in the Help.
Pearson's data with York's weights is the classic test for fitting with errors in both variables.
Model library
35 models, or your own equation
Every model has its own page with the equation, what each parameter means and tips for fitting it. A custom equation uses x and up to five parameters, A to E. curve.fit checks it as you type and suggests a matching built-in model.
- Arrhenius
- Cauchy
- Cubic
- Damped Oscillator
- Double Exponential
- Driven Oscillator Amplitude
- Exponential Decay (Half-life)
- Exponential Decay (Time Constant)
- Exponential with Offset
- Gaussian
- Gaussian on Linear Background
- Inverse
- Linear
- Logistic
- Logistic 4PL (Hill)
- Logistic 5PL
- Logistic with Baseline
- Lorentzian Peak
- Malus’s Law
- Natural Log
- Oscillator
- Poisson
- Power Law
- Power Law with Offsets
- Power Law with Vertical Offset
- Quadratic
- Quartic
- RLC Resonance
- Saturation (Michaelis–Menten)
- Shifted Reciprocal
- Single Slit Diffraction
- Stokes Law
- Two Slit Interference
- Weighted Mean
- X Log X
- Custom equation (A–E)
Lab-ready output
A one-page report for every fit
Every fit exports a PDF with the model and equation, the fitted parameters with their uncertainties, reduced χ², the plot with error bars and uncertainty band, and the residuals.
Example reports for the Pearson–York fit: Single PDF · Double PDF
- Single PDF for one report. Double PDF prints two copies side by side for lab partners.
- Titles and axis labels accept LaTeX math and symbols such as °, µ, ± and Greek letters.
- Browser Report opens the fit with full-precision tables, with CSV, JSON and Excel downloads.
- An XLSX workbook holds the same tables and the plot. The plot toolbar saves PNG or SVG images for slides.
- Each report is stamped with its session, fit ID and time, so an instructor can open the fit behind it.
Teaching a lab?
One method for every section
Every student uses the same fitting method and reporting conventions, whatever computer they have.
Get started
Try it with your own data
A guided walkthrough fits a sample dataset in about five minutes, in a separate practice tab.