standard deviation of two elements of a 3d matrix
1 回表示 (過去 30 日間)
古いコメントを表示
Greetings,
I have a 672 x 32 x 2800 matrix that I need to chop into a 672 x 2800 matrix but the rows need to be the standard deviation of the columns in the original 3d matrix. Here is what I am doing which is all wrong
new_col_data = zeros(672,2800);
new_col_data = [std(data, 0, 2),:]
I cannot figure this out. Can someone please tell me what is wrong?
Thank you
0 件のコメント
採用された回答
Shashank Prasanna
2013 年 6 月 28 日
編集済み: Shashank Prasanna
2013 年 6 月 28 日
A = rand(672,32,2800); % Some random data:
B = std(A,[],2); % Compute the standard deviation
B = squeeze(B); % Squeeze it
0 件のコメント
その他の回答 (2 件)
Sean de Wolski
2013 年 6 月 28 日
Sounds like you want to squeeze it!
squeeze(std(rand(60,30,45),0,2))
0 件のコメント
William
2013 年 6 月 28 日
1 件のコメント
Sean de Wolski
2013 年 6 月 28 日
Mine doesn't have a squeeze(blah,:). It's supposed to jsut be squeeze(blah)
参考
カテゴリ
Help Center および File Exchange で Logical についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!