Finding uncertainty of a slope

19 次查看(过去 30 天)
Bugrahan Guner
Bugrahan Guner 2023-8-28
I have 5 data sets. After I average each one of them within themselves, I fit a line to the resultant 5 data points. I would love to receive some suggestions toward how to find the +- uncertainty for the slope of this line and how to achieve it through MATLAB.
Thanks in advance!

回答(1 个)

Star Strider
Star Strider 2023-8-28
This is straightforward if you have the Statistics and Machine Learning Toolbox. Use regress to get the confidence intervals. The fitlm function provides probability values (that the slope and other parameters individually are different from zero) however not the confidence intervals.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by