Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, is already up and running.

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

Re: st: predictnl expression too long

From   Maarten Buis <>
Subject   Re: st: predictnl expression too long
Date   Fri, 8 Mar 2013 17:48:27 +0100

On Fri, Mar 8, 2013 at 5:17 PM, Richard J Swartz <> wrote:
> After reading the comments and help files on predict, it looks like predict() and xb() have set quantities they can produce involving the linear portion of the model (XB).  Is this correct?
> If so then, unfortunately the function I'm estimating cannot be simplified by predict() or xb() because  the function I want to predict use a subset of the linear component, (i.e. a subset of the predictors) as opposed to the full XB linear component.

The trick is that if you want the xb excluding the componenent
associated with variable x1 than you just type xb() - _b[x1]*x1, which
is often a lot shorter than explicitly typing out the components you
want to include.

-- Maarten

Maarten L. Buis
Reichpietschufer 50
10785 Berlin
*   For searches and help try:

© Copyright 1996–2016 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index