フィルターのクリア

Could anyone help me to fix the issue

1 回表示 (過去 30 日間)
Prabha Kumaresan
Prabha Kumaresan 2018 年 3 月 21 日
コメント済み: Prabha Kumaresan 2018 年 3 月 21 日
code:
unused_rows=1:6
while ~isempty(unused_rows)
N_UE_rows=2;
rows=unused_rows(randsample(length(unused_rows),N_UE_rows))
[~,idx]=find(ismember(unused_rows,rows))
unused_rows(idx)=[]
end
If i run the code it works.but the number of rows for each group keep on changing if i run the code again and again.But what should be done inorder to fix the number of rows say for example(13,24,56).If i run the code for the next time i should get the same rows in each group(13,24,56).
  2 件のコメント
KSSV
KSSV 2018 年 3 月 21 日
If the output is always same, then why to run the code? :)
Prabha Kumaresan
Prabha Kumaresan 2018 年 3 月 21 日
the reason for the output to be same is I need to check for the combinations of (15,24,36),(14,26,35) and (12,34,56).If the output is getting fixed,then the output for the first combinations should not reappear in the next combinations.

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

回答 (0 件)

カテゴリ

Help Center および File ExchangeStartup and Shutdown についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by