I have to generate 1000 numbers following mixed normal distribution, (80% N(0,1), 20% N(0,25)), and I have to show their distribution in the chart. And then compare with normal distrubution (graphical) and calculate mean, variance, skewness, kurtosis.
I have done this, but its not good :)
%LET N80=800;
%LET N20=200;
DATA MIXED_NORM;
DO REP=1 TO &N80;
X=RAND('NORM');
OUTPUT;
END;
DO REP=1 TO &N20;
X=RAND('NORM',0,25);
OUTPUT;
END;
RUN;
%LET N=1000;
DATA NORM;
DO REP=1 TO &N;
Y=RAND('NORM');
OUTPUT;
END;
RUN;
Can someone help me? Also, I cant use insight.
I have done this, but its not good :)
%LET N80=800;
%LET N20=200;
DATA MIXED_NORM;
DO REP=1 TO &N80;
X=RAND('NORM');
OUTPUT;
END;
DO REP=1 TO &N20;
X=RAND('NORM',0,25);
OUTPUT;
END;
RUN;
%LET N=1000;
DATA NORM;
DO REP=1 TO &N;
Y=RAND('NORM');
OUTPUT;
END;
RUN;
Can someone help me? Also, I cant use insight.