|
Hello dear list members,
For simulation purpose I need 2 RV's (X1, X2) with the same correlation
(r=0,3) to a target RV Y, same means (Y, X1, X2 = 1) but different stddev.
(X1 vs. X2 = 0,2 vs. 0,6)=> differing variation coefficients!!!
With "COMPUTE 0,3*Y+SQRT(1-(0,3 ** 2))*Y_1" i only get variables with r =
0,3 when the used Dummy-Var for calculating (Y_1) has the same
stddev/variation coefficient like my target-variable Y.
Here's my try. Does anyone know how to do that?
Greetings
Lenz
*Target-Variable.
*=============================================.
COMPUTE Y = RV.NORMAL(1,0.2) .
*Y_1,2,... = Dummy-RV for calculating RV's correlated with Y (X1,
X2, ...).
*--------------------------------------------------------------------.
COMPUTE Y_1 = RV.NORMAL(1,0.2) .
COMPUTE Y_2 = RV.NORMAL(1,0.6) .
*calculating RV's correlated with Y (X1, X2, ...), r = 0,3.
*-----------------------------------------------------------------------.
COMPUTE X1 = 0.3*Y+SQRT(1-(0.3 ** 2))*Y_1 .
COMPUTE X2 = 0.3*Y+SQRT(1-(0.3 ** 2))*Y_2 .
EXE.
|