Liz's Stata Guide

Commands: Regressions

This page covers commands that estimate regression models on the data.

Estimates an ordinary least squares regression: y = a + bX
reg depvar indvar1 indvar2, r

probit; dprobit
Estimates a probit model: P(y = 1 | X) = Φ(a + b X) where Φ is the cumulative distribution function of the standard normal random variable.
probit depvar indvar1 indvar2

logit; logistic
Estimates a logit regression: P(y = 1) = λ(a + bX) where λ(z) = ez / (1 + ez)
logit depvar indvar1 indvar2

Estimates fixed effects models: yit = a + b xit + ci
areg depvar indvar1 indvar2, absorb(groupvar)

Estimates fixed effects models, random effects models and others.
xtreg depvar indvar1 indvar2, fe i(groupvar)   - or -
xtreg depvar indvar1 indvar2, re i(groupvar)

ivreg needs to be rewritten
Estimates an instrumental variable model.
ivreg depvar convar (indvar = insvar1 insvar2)

predict needs to be rewritten
Calculates predicted values based on a previously estimated regression.
predict varhat

last modified: 1 May 2007