Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

RE: st: xtsum formulas

From   "Nick Cox" <>
To   <>
Subject   RE: st: xtsum formulas
Date   Thu, 6 Jul 2006 12:15:55 +0100

Quite so. Indeed, knowing that -xtsum- is implemented as an .ado file
(strictly, not a .do file) means that 

viewsource xtsum.ado 

will give you a view of the code, without (a) needing
to doing a -which- to find out precisely where the 
file is, or (b) any risk of modifying the code. 

This tip is explained in more detail in 

SJ-6-1  pr0022  . . . . . . . . . . . Stata tip 30: May the source be with you
        Q1/06   SJ 6(1):149--150                                 (no commands)
        tip for using viewsource to locate and view source
        code or text files

and in "Thirty-three Stata Tips" from StataCorp. 


Neil Shephard
> On 7/6/06, Podestà, Federico <> wrote:
> > I have (I think) a simple problem: I would like to know 
> formulas used by the -xtsum- command to obtain the betweem 
> standard deviation and the within standard deviation.
> > In particular I would like to know Stata code to compute 
> such statistics by hand solving all parts of the formulas 
> step by step.
> The formulas for the methods implemented in Stata (at least those I've
> ever had recourse to look up) are given in the manuals, in this
> instance it will be [XT].
> In this instance because -xtsum- is implemented as a do-file....
> . which xtsum
> /usr/local/stata9/ado/base/x/xtsum.ado
> *! version 1.0.9  06aug2004
> can look at the code yourself by viewing the relevant file in a
> text-editor.
> (Be wary of modifying the file which will break things.  If you want
> to make modifications, don't, instead clone the do-file to your
> personal-ado file and rename it, and make modifications to that).

*   For searches and help try:

© Copyright 1996–2021 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index