Archive

Posts Tagged ‘confidence interval’

Basic Statistics in sage

February 13, 2011 Leave a comment

No need to spend big bucks in the purchase of expensive statistical software packages (SPSS or SAS): the R programming language will do it all for you, and of course sage has a neat way to interact with it. Let me prove you its capabilities with an example taken from one of the many textbooks used to teach the practice of basic statistics to researchers of Social Sciences (sorry, no names, unless you want to pay for the publicity!)

Estimating Mean Weight Change for Anorexic Girls

The example comes from an experimental study that compared various treatments for young girls suffering from anorexia, an eating disorder. For each girl, weight was measured before and after a fixed period of treatment. The variable of interest was the change in weight; that is, weight at the end of the study minus weight at the beginning of the study. The change in weight was positive if the girl gained weight, and negative if she lost weight. The treatments were designed to aid weight gain. The weight changes for the 29 girls undergoing the cognitive behavioral treatment were

\begin{array}{rrrrrr} 1.7&0.7&-0.1&-0.7&-3.5&14.9\\3.5&17.1&-7.6&1.6&11.7&6.1\\1.1&-4.0&20.9&-9.1&2.1&1.4\\-0.3&-3.7&-1.4&-0.8&2.4&12.6\\1.9&3.9&0.1&15.4&-0.7\end{array}

Read more…