Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: problems with corr2data command
From
"Hauck, Katharina D" <[email protected]>
To
"[email protected]" <[email protected]>
Subject
st: problems with corr2data command
Date
Wed, 5 Feb 2014 10:33:24 +0000
Dear Stata community,
For teaching purposes, I have to generate eight datasets of correlated
random variables with different distributions. Correlations, means and SD
of all variables have to be the same across datasets. I am using the
corr2data command but I have several issues: First, I cannot generate
discrete variables (or only with messy recoding afterwards), I cannot set
max and min values for the generated variables (again, requiring messy
recoding afterwards), and I seem to make a mistake with the correlation
matrix because when I check correlations after generation they are not
what they should be. Any tips for handling this command, or suggestions on
alternative commands? I am considering doing this all in MatLab, again,
any experiences highly welcome.
Thanks!
Katharina.
--------
Katharina Hauck
Centre for Health Policy
Imperial College Business School
London, United Kingdom
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/