Extracting a subset data from column 2 based on column 1
2 次查看(过去 30 天)
显示 更早的评论
Hi, I'm trying to extract a subset of data from column 2 that corresponds with column 1. For example, I need to extract values in column 2 that correspond to the values 40-70 in column 1. Column 1 is the time and Column 2 is the magnitude. I want to extract the magnitude for a certain time set.
Thanks!
0 个评论
采纳的回答
Iuliu Ardelean
2021-2-10
Hey
I assume your data looks something like this:
time = 1:100;
magnitude = rand(1,100);
selection = magnitude(time>40 & time<70);
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Octave 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!