How to do data selection from a graph to extract the evenly spaced data points ?
9 ビュー (過去 30 日間)
古いコメントを表示
Dear peers, i would like to select or extract the data that the Y axis is more than 0.001. and then select 60 points that are evenly spaced out in the selected graph area.
for eg: The original graph is generated by matlab simulink. and would like to select the data that are in the Red rectangle.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/192947/image.jpeg)
the outcome is expected as follow: 30 data points that evenly space (closet) that are selected from each peaks.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/192948/image.jpeg)
What is the best search method to find the evenly space data points? and i would use this algorithm for different graphs.
Thank you very much
0 件のコメント
採用された回答
KSSV
2018 年 8 月 1 日
Let X and Y be your data arrays.
N = 30 ;
xi = linspace(min(X),max(X),N) ;
yi = interp1(X,Y,xi) ;
plot(xi,yi)
axis([-100 100 0 0.04])
2 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Graph and Network Algorithms についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!