Please enable JavaScript to view this site.

This guide is for an old version of Prism. Browse the latest version or update Prism

Navigation: REGRESSION WITH PRISM 7 > Linear regression with Prism > How to: Linear regression

Advice: When to fit a line with nonlinear regression

Scroll Prev Top Next More

Linear regression is a special case of nonlinear regression

Linear regression is just a simpler, special, case of nonlinear regression. The calculations are a bit easier (but that only matters to programmers). You can use Prism's nonlinear regression analysis to fit a straight-line model, and the results will be identical to linear regression.  

How to convert a linear regression analysis to nonlinear regression

To convert linear regression to nonlinear regression, bring up the Parameters dialog for linear regression, and click "More Choices" at the bottom.

Nonlinear regression offers more options

Conceptually, linear regression is just a special case of nonlinear regression. But Prism offers many more options when using nonlinear regression. Therefore, it often makes sense to use Prism's nonlinear regression analysis to fit a straight line. In particular, the nonlinear regression analysis lets you:

Fit to both a linear and nonlinear model, and compare the two models.

Apply differential weighting.

Automatically exclude outliers.

Use a robust fitting method.

Perform a normality test on the residuals.

Inspect the correlation matrix or dependencies.

Compare the scatter of points from the line with the scatter among replicates with a replicates test.

Report the best-fit values with 90% confidence limits (or any others). Prism's linear regression analysis only reports 95% CI. Nonlinear regression lets you choose the confidence level you want.

Report the results of interpolation from the line/curve along with 95% confidence intervals of the predicted values. Prism's linear regression analysis does not include those confidence intervals.

With linear regression, the SE of the slope is always reported with the slope as a plus minus value. With nonlinear regression, the SE values are a separate block of results that can be copy and pasted elsewhere.

Use global nonlinear regression to fit one line to several data sets. Or share the intercept or slope among several data sets, while fitting the other parameter individually to each data set.

Run a Monte Carlo analysis.

When you enter data with multiple replicates at each X value, Prism's nonlinear regression can perform the replicates test to ask whether the data deviate systematically from the straight line model. Prism does not offer the replicates test with linear regression.

Test whether the slope (or intercept) significantly differs from some proposed value. For example, test whether the slope differs from a hypothetical value of 1.0, or whether an intercept differs significantly from 0.0.

Lines that must be fit with nonlinear regression

There are two situations where you might first think that linear regression is the best analysis, but in fact nonlinear regression is necessary:

If your Y axis uses a logarithmic or probability scale, then a straight line on the graph is created by a nonlinear model. In this case, although the line on the graph is straight, the model is not actually linear. You need to fit the 'line' with nonlinear regression.

If you want to fit two lines to different segments of the data, this cannot be done with Prism's linear regression analysis. However, Prism's nonlinear regression can fit segmental linear regression.

 

© 1995-2019 GraphPad Software, LLC. All rights reserved.