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

AW: st: Speed problems using Stata 8.2


From   "Kroll, Lars Eric" <[email protected]>
To   <[email protected]>
Subject   AW: st: Speed problems using Stata 8.2
Date   Fri, 23 Jul 2004 16:29:04 +0200

Thanks Daniel and Nick for your fast help.

I changed your Do-File a bit (see below)

After all there is one conclusion for me: Stata is affected by the OS but unexpected:
=====================================================================================
PIII   800 19 sec Win NT 4 SP6
PIV    2,6  8 sec Win NT 4 SP6
PIV HT 2,8 26 sec Win XP!! 

No other Applications..

Thanks a lot,

Lars

Do File:
============
capture clear
capture log close
 program define lnsim, rclass
         syntax [, obs(integer 1) mu(real 0) sigma(real 1)]
         drop _all
         set obs `obs'
         tempvar z
         gen `z' = exp(`mu' + `sigma'*invnorm(uniform()))
         summarize `z'
         return scalar mean = r(mean)
         return scalar Var  = r(Var)
    end

display  "Start: `c(current_time)'"
quietly simulate "lnsim, obs(1000)" mean=r(mean) var=r(Var), reps(10000)
display  "Stop: `c(current_time)' "
clear

*
*   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