Mathematica 9 is now available
Student Support Forum
Student Support Forum: 'Loop+RandomChoice' topicStudent Support Forum > General > "Loop+RandomChoice"

Next Comment >Help | Reply To Topic
Author Comment/Response
11/29/12 10:45am

Dear all,

I would like to know if there is a possibility to use a loop within the RandomChoice command?

for example:

ha is a nested table with 5 probabilities each period for in total 3 periods:


rc1=RandomChoice[ha[[1]] -> {1, 2, 3, 4, 5} , 10]

rc1 gives me 10 random choices for period 1.

Is there a possibility to get the the random choices for all three periods? Something like a loop for ha[[i]],{i,1,3}?

Thank you in advance for your help.


URL: ,

Subject (listing for 'Loop+RandomChoice')
Author Date Posted
Loop+RandomChoice anna 11/29/12 10:45am
Re: Loop+RandomChoice Bill Simpson 11/29/12 3:32pm
Re: Re: Loop+RandomChoice anna 11/30/12 03:31am
Next Comment >Help | Reply To Topic