{smcl} {* 2005-02-06}{...} {hline} help for {hi:_pecidelta}{right:2/6/2005} {hline} {title: Utility to implement the delta method for calculating confidence intervals} {p 8 15 2}{cmd:_pecidelta} [{cmd:,} {cmdab:s:ave} {cmdab:d:iff}] {title: Description} {p 4 4 2} {cmd:_pecidelta} is a utility command that calculates confidence intervals for prediction and discrete changes by {search delta} method using analytical derivatives. It applies to {help logit}, {help probit}, {help cloglog}, {help ologit}, {help oprobit}, {help gologit}, {help mlogit}, {help poisson}, and {help nbreg}. {title: Options} {p 4 8 2} {cmd:save} saves current values of indepenent variables and predictions for computing changes using the diff option. {p 4 8 2} {cmd:diff} computes difference between current predictions and those that were saved. {title: Global Matrices} {p 4 4 2} The second row of the following matrices contains predicted probabilities and the sixth row contains differences for predicted probabilities. {p 4 8 2} peupper: _pecidelta calculates confidence intervals for prediction and place upper end into the global matrix peupper. {p 4 8 2} pelower: _pecidelta calculates confidence intervals for prediction and place lower end into the global matrix pelower. {title: Examples} {p 4 8 2}{cmd:._pebase `if' `in' , `x' `rest' `choices' `all'}{p_end} {p 4 8 2}{cmd:.mat `tobase' = r(pebase)}{p_end} {p 4 8 2}{cmd:._pepred, `level' `maxcnt'}{p_end} {p 4 8 2}{cmd:.local maxc = r(maxcount)}{p_end} {p 4 8 2}{cmd:.local lvl = r(level)}{p_end} {p 4 8 2}{cmd:.capture _return drop pepred}{p_end} {p 4 8 2}{cmd:._return hold pepred}{p_end} {p 4 8 2}{cmd:._return restore pepred, hold}{p_end} {p 4 8 2}{cmd:...}{p_end} {p 4 8 2}{cmd:...}{p_end} {p 4 8 2}{cmd:...}{p_end} {p 4 8 2}{cmd:._pecollect, inout("`io'") level(`lvl') /// }{p_end} {p 4 8 2}{cmd:. maxcount(`maxc') `diff' `reps'}{p_end} {p 4 8 2}{cmd:._pecidelta, `save' `diff'}{p_end} {hline} {p 2 4 2}Authors: J. Scott Long & Jun Xu{p_end} {p 11 4 2}{browse www.indiana.edu/~jslsoc/spost.htm}{p_end} {p 11 4 2}spostsup@indiana.edu{p_end}