Using cell array to find corresponding values of a numeric array

2 ビュー (過去 30 日間)
olimpia_m
olimpia_m 2018 年 11 月 27 日
コメント済み: olimpia_m 2018 年 11 月 27 日
Hello,
I am trying to create a loop that performs some calculations on a large data set and I am stuck in the following:
Initially, the loop finds the peaks from the data set along with the location of these peaks within the column and returns a cell array {1x8}
I would like afterwards to find for each internal cell the corresponding time locations in t. Any suggestions? I
This is where I am getting up to now. Everything I tried for the next step does not work.
load X.mat % [15000x8]
t=0:0.5:1200; % corresponding time column for data
for j=1: columns
c1(:,j)= X (1:end,j);
[cmax{j},locs{j}]=findpeaks(c1(:,j),'MinPeakHeight',80);
end

回答 (1 件)

madhan ravi
madhan ravi 2018 年 11 月 27 日
  1 件のコメント
olimpia_m
olimpia_m 2018 年 11 月 27 日
Hi,
I have found the index from each individual table in the cell array. But now I want to use that to find the corresponding value in another array and store it again, effectively creating a new 1x8 array.
I am not sure how to use the quoted answer to do that

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

カテゴリ

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

タグ

製品

Community Treasure Hunt

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

Start Hunting!

Translated by