[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: Random walk simplex

From   "Akshay Shanker" <>
To   <>
Subject   st: Random walk simplex
Date   Fri, 23 Oct 2009 13:55:13 +1100

Hi all, 
I was hoping someone would be able to  help me out. 
I am trying to create a random walking simplex in STATA. The procedure
to create a random K dimension simplex seems straightforward:
- generate K uniform RVs Xi...Xk in (0,1)
- each point in the random simplex is then i/(sum(-logXi)). 
But how would I go about getting this simplex to do a random walk in
Stata? More specifically, how can I choose a markov like draw of
-logXi,t based on an already given -logXi,t-1. There seems to be a
metropolis-hastings algo which selects this draw from a gamma
distribution with a mean of Xi,t-1 - but not sure how to do this in
STATA. Ideally I'd like to be able to generate a KxN matrix where the
coloumns are the simplex, which walk over the rows. 

This email has been scanned by the MessageLabs Email Security System.
For more information please visit 

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index