Re: need little help - no longer!
- To: mathgroup at smc.vnet.net
- Subject: [mg23548] Re: [mg23530] need little help - no longer!
- From: Wagner Truppel <wtruppel at uci.edu>
- Date: Sat, 20 May 2000 03:10:25 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
"Thank you!" to both Johannes Ludsteck and Kenneth Levasseur, who supplied me with solutions to my query. As Johannes pointed out, the Statistics`MultiDiscreteStatistics` package has facilities for drawing random numbers from a multinomial probability distribution. However, I personally prefer Ken's solution: RandomIndex[m_] := (m /. {{a__, b___} :> Length[{a}] /; Plus[a] >= #}) &[Random[]] Once again, thank you both. Wagner