ThreeSLS-methods: ~~ Methods for Function 'ThreeSLS' in Package 'momentfit' ~~

ThreeSLS-methodsR Documentation

~~ Methods for Function ThreeSLS in Package momentfit ~~

Description

Method to estimate system of equations by Three-Stage least squares (3SLS) or, as a special case, by Seemingly Unrelatd Regressions (SUR).

Usage

## S4 method for signature 'slinearModel'
ThreeSLS(model, coefOnly=FALSE, qrZ=NULL,
Sigma=NULL)
## S4 method for signature 'rslinearModel'
ThreeSLS(model, coefOnly=FALSE, qrZ=NULL,
Sigma=NULL)

Arguments

model

An object of class "slinearModel" in which instruments are the same in each equation and the error terms are homoscedastic.

coefOnly

Should the method return the only the coefficients or create an object of class "sgmmfit".

qrZ

The qr decomposition of the common instruments. It is mostly used by gmmFit to avoid recomputing it in iterative GMM or CUE. It should not be used directly unless the user knows what he is doing.

Sigma

The covariance matrix of the residuals. If not provided, it is computed using the residuals of the equation by equation two-stage least squares. It should not be used directly unless the user knows what he is doing.

Methods

signature(model = "slinearModel")

The method is specifically for system of linear models with the same instruments and homoscedastic errors. It becomes SUR as a special case when the instruments are the union of all regressors.

signature(model = "rslinearModel")

This method is for restricted models that does not impose cross-equation restrictions. With such restrictions 3SLS is not possible as we can no longer write the model as a system of equations.


momentfit documentation built on Sept. 20, 2023, 3:01 a.m.