Good afternoon. I tried to generate discrete uniform random variables
using randgen, but it appears that the function cannot take negative
values as bounds for the distribution (if both minimum and maximum are
positive, then everything works fine. If either one or both bounds are
negative numbers, it goes berserk).
The script is
nulldata 100
genr scalar lb=-5
genr scalar ub=1
genr series Z1 = randgen(i,lb,ub)
and the summary statistics are
Summary statistics, using the observations 1 - 100
for the variable 'Z1' (100 valid observations)
Mean 2.7488e+009
Median 4.2950e+009
Minimum 0.00000
Maximum 4.2950e+009
Standard deviation 2.0720e+009
C.V. 0.75378
Skewness -0.58333
Ex. kurtosis -1.6597
5% percentile 0.00000
95% percentile 4.2950e+009
Interquartile range 4.2950e+009
Missing obs. 0
--
Alecos Papadopoulos
Athens University of Economics and Business, Greece
Department of Economics
cell:+30-6945-378680
fax: +30-210-8259763
skype:alecos.papadopoulos