How to make matrix after using findpeaks?
Mostra commenti meno recenti
Hi,now i have a question about cell after using "findpeaks". Its very simple question, i guess. I used "findpeaks" and now i have a cell data like follows.
for k=1:10
B{k}=findpeaks(value(:,k),'NPeaks',6);
end
And now cell{B} is consist with some data like this:
[1, 0.35315, 0.35267, 0.25845, 0.14570, 0.14683] [1, 0.25243, 0.19255, 0.14261] [1, 0.28165, 0.17765, 0.14319, 0.12926] .....
Then i want to convert these data to array(matrix) like follows.
1 1 1
0.35315 0.25243 0.28165
0.35267 0.19255 0.17765
0.25845 0.14261 0.14319
0.14570 0.12926
0.14683
if you some idea to solve this problem, please give me some advice. thanks.
1 Commento
KSSV
il 25 Set 2017
YOu can convert cell B to a matrix if every cell has same number of elements, else you cannot convert. Read about cell2mat.
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su データ型の変換 in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!