Statalist


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

Re: st: Generating simulated data with binary variables


From   Maarten buis <[email protected]>
To   [email protected]
Subject   Re: st: Generating simulated data with binary variables
Date   Fri, 14 Aug 2009 20:32:20 +0000 (GMT)

--- On Fri, 14/8/09, John Antonakis wrote:
> I know how to use corr2data to generate matrixes with know
> properties. However, what if one would like to generate
> binary data that correlates at a specific value with a
> continuous or other binary data? Is there a direct way to do
> this instead of generating continuous data and then
> dichotomizing it?

Some tricks for doing that are discussed in:
Maarten L. Buis (2007) Stata tip 48: Discrete uses for 
uniform(). The Stata Journal 7(3):434-435.

You can find a pre-publication draft at:
http://home.fsw.vu.nl/m.buis/wp/discrete.html

Hope this helps,
Maarten

-----------------------------------------
Maarten L. Buis
Institut fuer Soziologie
Universitaet Tuebingen
Wilhelmstrasse 36
72074 Tuebingen
Germany

http://home.fsw.vu.nl/m.buis/
-----------------------------------------


      

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



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