Hi all, I'm searching for a way to select random variables from each column of a matrix, together with two different random parameters between 0 and 1 (so, not integer...), without losing the i.i.d. condition (Indipendent and Identically Distributed).
What I want to do is to obtain a vector v 1x6 with in the first 4 column a random variable taken from each column of A, and in the last 2 column of v 2 values between 0 and 1.
The only way that I found to do it is to use 2 times the function randi: one for the random selection of the four values from A, and one for the random selection of the 2 values between 0 and 1. However, using 2 times the function randi, the elements in v will be not i.i.d.
There is a way to use just one time the function for the overall random selection?