Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: how PC works


From   "Levy Lee" <[email protected]>
To   <[email protected]>
Subject   st: how PC works
Date   Mon, 6 Sep 2004 15:59:23 +0800

Dear listers,

    please test the following code:

    clear
    set obs 1000
    gen x = uniform()
    egen pc = pc(x)


sum

    Variable |       Obs        Mean    Std. Dev.       Min        Max
-------------+--------------------------------------------------------
           x |      1000    .5019275     .291899   .0007097   .9980542
          pc |      1000          .1    .0581556   .0001414   .1988443


the above code generate a variable "pc", which is distributed between 0 and
.20, i do not know why? as the help file told me that the new variable
should be between 0 and 100.

Can you tell me the reason? is it a bug of stata?

thanks

Levy

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   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