Info

此问题已关闭。 请重新打开它进行编辑或回答。

Could anyone help me how to solve the following issue.

1 次查看(过去 30 天)
If i run this code i am getting the result such that in each column i am getting one values out of 5 and the rest are zero.If i want to get the more than one value out of 5 in each column how it can be resolved.Pls help.
G=rand(5,10)
siz = size(G);
idx = sub2ind(siz, randi([1,N_UE(t)], 1, siz(2)), 1:siz(2));
C = zeros(siz);
C(idx) = G(idx)

回答(0 个)

此问题已关闭。

标签

Community Treasure Hunt

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

Start Hunting!

Translated by