Hi Fabricio,
The tobit model via the survival package does not output fitted values in
the model output (the zelig step). Since the observations are censored, the
censoring has to be applied via simulation. Therefore, I suggest that you
use
x.out <- setx(z.out, fn = NULL)
s.out <- sim(z.out, x = x.out)
fv <- apply(s.out$qi$ev, 2, mean)
This will give you a vector of expected values (fv) that will correspond to
each observation in your data (after appropriate list-wise deletion, and so
many not be the same as the number of rows in the data set).
If you have like 10,000+ observations, this may take a few seconds, so just
be patient.
Yours,
Olivia
2010/8/20 Fabrício Mendes Fialho <fabriciofialho(a)gmail.com>
Hi Zelig users,
I'm running some tobit models and trying to obtain the predicted values. I
try the command z.out$fitted.values (the same command I've used to obtain
fitted values for OLS, for instance), and receive the message:
z.out1$fitted.values
NULL
Is there any command to get predicted values from a tobit model?
Best,
Fabrício Mendes Fialho
site:
sites.google.com/site/fabriciofialho/
e-mail: fabriciofialho(a)gmail.com