Fitting exponential
古いコメントを表示
Hi, I want to fit my data with an exponential curve. I use fit and fittype=exp. So far no problem. But now I only want to use the first 600 data points and the last 200 datapoints (every trace has 15000 datapoints) and make an exponential fit over the whole trace only using this datapoints.
Can anybody help me which methods to use?
Thanks for your efforts!
2 件のコメント
Rick Rosson
2011 年 8 月 4 日
Are you asking for help with which methods to use for curve fitting, or are you asking for help in how to segregate the data in MATLAB into two separate sets of data?
fcarl
2011 年 8 月 4 日
採用された回答
その他の回答 (3 件)
the cyclist
2011 年 8 月 4 日
0 投票
If "x" is your explanatory variable, then it should be as simple as using x([1:600,end-199:end]), do similar for your response variable,and run fit() just as you did with "no problem" before. Or is it more complicated than that?
fcarl
2011 年 8 月 4 日
0 投票
5 件のコメント
the cyclist
2011 年 8 月 4 日
I'm confused. Sounds like you have a bunch of (t,x) pairs. You want to fit an exponential to the entire range of t, using data from only the small-t region and the large-t region. Without using the data from the middle-t region, I don't see how they can inform the fit. I'm guessing I'm misunderstanding something. Maybe you could post some code, or a figure, that gives more detail about what you are trying to do.
[Also, your note would be better placed as a comment on my answer, rather than as a separate answer.]
Yoav Livneh
2011 年 8 月 4 日
Maybe you could do the cyclist's suggestion and then use interp1 to interpolate the middle section.
fcarl
2011 年 8 月 4 日
Rick Rosson
2011 年 8 月 4 日
Also, what is your time scale? You have 15000 points, but I assume that the time increment is not actually 1, but something much smaller. Do you know the sampling rate Fs and/or the time increment dt = 1/Fs?
fcarl
2011 年 8 月 4 日
カテゴリ
ヘルプ センター および File Exchange で Linear Predictive Coding についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!