Plot trend line based on data imported from excel

3 ビュー (過去 30 日間)
Tsvetan Donov
Tsvetan Donov 2017 年 6 月 10 日
コメント済み: Rena Berman 2017 年 6 月 13 日
Hi, I have used matlab for some time now, for importing data from excel and plotting it in matlab because the graphs look much better. This is the first time I have to do a trend line of the data. What is the way to do it because in insert there is no trend line option. In excel this is much simpler.
Do you have any idea how to do it?
I want to find trend line for the orange line separate from the blue line as well as a combined trend from both data sets.
I have attached a photo you can see the data there.
Best Regards,
Tsvetan
  2 件のコメント
Rena Berman
Rena Berman 2017 年 6 月 13 日
(Answers Dev) Restored edit

サインインしてコメントする。

回答 (2 件)

Star Strider
Star Strider 2017 年 6 月 10 日
No image and no data.
If you just want to plot a linear least-squares fit to your data, see if the lsline (link) function will do what you want.
The polyfit and polyval functions can create polynomial fits to your data, and will return parameters for the fit.

Tsvetan Donov
Tsvetan Donov 2017 年 6 月 10 日
I am sorry, it didnt upload for some reason.

カテゴリ

Help Center および File ExchangeSpreadsheets についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by