New function using the delta method to calculate confidence intervals and prediction intervals

Skip to first unread message

Greg Pelletier

Dec 25, 2023, 3:45:51 PM12/25/23
to lmfit-py
Dear all,

Attached is a new function named delta_method to calculate the confidence interval of the nonlinear regression curve and prediction interval for new observations

This new function uses the lmfit for the variance-covariance matrix of the model parameters, and the best-fit parameter values, to calculate the confidence interval of the curve, and the prediction intervals for any new observations. The user may specify any signficance level (e.g. use alpha=0.05 for 95% confidence intervals and 95% prediction intervals). 

The function uses the delta method, which is described in detail in Section 5.1 of this online lecture:

This new delta_method function is intended to be an alternative to eval_uncertainty() for use in estimating confidence intervals and prediction intervals.

Best regards,

Greg Pelletier
Reply all
Reply to author
0 new messages