[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
Re: st: Why does -anova- calculate repeated effects (F) twice?
Ken Higbee <firstname.lastname@example.org>:
> You are correct that a speed improvement is possible here. It is
> something I have thought about and will some day implement.
> The main reason why Stata's -anova- is doing some of the
> computations twice has to do with the way the code was structured
> long ago when results were returned as _result(#) instead of in
> e() or r(). (Some list members will remember those days. How
> many of you remember typing -disp_res- and then either going back
> to the manuals to figure out what _result(6) was or trying to
> guess it by matching the number with the numbers in the output.)
> Some time in the future I would like to alter -anova- to return
> information (mean squares etc.) for each term in the -anova-.
> After I do this the table presented for the repeated measures
> corrections will not need to recompute the F stat, and will be
> presented very quickly. Also, replay of an -anova- would then be
> almost instantaneous.
Thanks for the explanation. I had a feeling that it was something like that.
I know that making changes to old code sometimes means a complete rewrite of
the code and that it is not a task that one should look too easy on.
However, there might be a simpler solution to this particular problem,
although maybe not so neat as your suggestion.
What if one could have an option that would just omit the first calculation?
This could (possibly) be implemented with a -fastrepeated()- option that one
could optionally use instead of the -repeated()- option. The result would
(of course) be an incomplete anova table but then, I'm seldom interested in
the main anova table for the repeated effects. My interest is in the df, F,
epsilon and corrected p-values that are calculated later.
Anyway. That's just a thought. Until some day.
Thanks again and keep up the good work.
Department of Psychology
Stockholm University &
National Institute for
* For searches and help try: