Hi,

I've generated two variables, let's call them y1 and y2, and I want to generate a quantile-quantile plot comparing their quantiles to those of a chi-squared random variable with one degree of freedom. I can do this by simply entering
Code:
qchi y1
qchi y2
However, I want to combine these on a single graph. I can add an additional scatterplot using the -addplot- option, but for this I need a variable containing the corresponding quantile of the chi-squared (1) distribution for each value of y2, so that I can then enter
Code:
qchi mlrt2, addplot(scatter y2 x2)
But what is the best way to generate x2 in a way consistent with what -qchi- does? Thanks