transform cfit (fitted data) into a numeric data array

조회 수: 79 (최근 30일)
sermet OGUTCU
sermet OGUTCU 2021년 2월 18일
답변: Vinnie Pepi 2021년 2월 18일
f=fit(x,y,'linearinterp');
I need to save f fitted numeric data from the original data into a different array such as;
fitted_data=f
How I can transform cfit type of fitted data to the numeric (double) fitted data?

채택된 답변

Vinnie Pepi
Vinnie Pepi 2021년 2월 18일
If I understand your question, it looks like you want to get the fitted data as an array of doubles.
According to this documentation:
You can supply the fit with a range of values that you are looking for like so:
xi = (2000:10:2050).';
fitted_data = f(xi)
Hope this helps.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Get Started with Curve Fitting Toolbox에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by