Picking data from graph?
2 ビュー (過去 30 日間)
古いコメントを表示
Nurfaiz Fathurrahman
2021 年 11 月 22 日
コメント済み: Nurfaiz Fathurrahman
2021 年 11 月 23 日
I have a sample signal below, I just want to retrieve the data in the red box for the next step of processing, how do I do it?
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/808629/image.png)
4 件のコメント
Walter Roberson
2021 年 11 月 22 日
How should the program know where to start extracting? How should the program know where to stop extracting ?
Is the time range fixed? Have the times been input by the user? Does the program need to detect the first minima and extract everything to the sixth minima ?
採用された回答
Bjorn Gustavsson
2021 年 11 月 22 日
If you have the signal S, the corresponding sample-times t and the start and stop-times t1 and t2 you can select the signal in the intervall:
S1to2 = S(t1<t&t<=t2);
If you want to select the time-interval from the graph, have a look at the help and documentation of ginput, it is a function that allows you to select points in graphs. You could use that to select 2 points (you will/can get bot the x and y-values of selected points) to give you t1 and t2.
HTH
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で DTMF についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!