Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: AW: Store T-Statistic from Model?

From   "Martin Weiss" <>
To   <>
Subject   st: AW: Store T-Statistic from Model?
Date   Fri, 4 Jun 2010 17:09:56 +0200


This is an inefficient way to store scalars, but you can do it:

sysuse auto, clear
reg price weight length
gen tstatforweight=_b[weight]/_se[weight]

A -local- would be better.

Note Maarten`s SJ article


-----Ursprüngliche Nachricht-----
[] Im Auftrag von JABBER2142
Gesendet: Freitag, 4. Juni 2010 17:01
Betreff: st: Store T-Statistic from Model?


Is it possible to store the T-statistics from a regression output into
a variable?  E.g. In a completely hypothetical example, if I conducted
a basic regression like "regress wage education" and the Stata output
said the T-statistic was 30, could I store this somewhere?  It is
possible to store the coefficient of said regression (gen coef =
_b[education]) or various stats about the entire model ( gen r2 =
e(r2) ) but I can't figure out where (or if?) the T-statistic is

Thanks much,
*   For searches and help try:

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index