[R] Some matrix and sandwich questions

Achim Zeileis Achim.Zeileis at wu-wien.ac.at
Tue Oct 30 18:45:21 CET 2007

On Tue, 30 Oct 2007, Michael Ash wrote:

> On 10/30/07, Christian Ritz <ritz at life.ku.dk> wrote:
> > in the MLE setting the score function (no expectation taken) is the
> > estimating function. So for the OLS situation the basic estimating
> > function is: (in the terminology of Zeileis' paper)
> >
> > psi(x,y,beta) = (y - x^t beta) x^t
> Thanks!  That was extremely helpful---maybe it could even be added to
> the documentation of estfun() and meat()

Sorry for coming so late to the thread (and thanks to Christian for
pointing out how sandwich works :-)).

The estimating function is the derivative of the objective function wrt to
the parameter vector. The empirical estimating function is the estimating
function evaluated at the observed data and the estimated parameters. This
is explained in Section 4.2 of the JSS 16(9) paper which is contained in
the package as
  vignette("sandwich-OOP", package = "sandwich")

But I'll follow your suggestion and add a bit more detail to the man page
as well.

> (Having the OLS example in the bread() documentation made it much
> easier for me to understand the broader concept.)

There is the analogous example in the examples section of the estfun()

If you want to see more details about the OLS case, have a look at
which is also contained in the package as
  vignette("sandwich", package = "sandwich")


More information about the R-help mailing list