Randomizing set of value using normal distribution?
1 回表示 (過去 30 日間)
古いコメントを表示
Hi, I had a 7000x4000 Matrix of topographic data that I split into 10x10 matrices (Split by going every 10 rows and 10 columns) using this code:
filename = '1m_studyarea_data.xlsx';
A = xlsread(filename);
B=mat2cell(A,10*ones(400,1),10*ones(700,1))
C=cellfun(@(x) x(randi(100)),B)
I need it to randomly select 1 number out of the 100 in each matrices using normal distribution?
Thanks, Akshay
0 件のコメント
回答 (2 件)
John D'Errico
2016 年 8 月 10 日
編集済み: John D'Errico
2016 年 8 月 10 日
You asked this exact question before. What was wrong about that answer? The only difference is that you have now asked how to randomly select 1 number using the normal distribution, whereas the last time, you just stated a random requirement, with no distribution. Since a normal distribution is unbounded, your question makes no mathematical sense.
0 件のコメント
Image Analyst
2016 年 8 月 11 日
I answered this in your duplicate question. Go there to see the answer.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Creating and Concatenating Matrices についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!