# LIML: Limited Information Maximum Likelihood Ratio (LIML) Estimator In ivmodel: Statistical Inference and Sensitivity Analysis for Instrumental Variables Model

## Description

`LIML` computes the LIML estimate for the `ivmodel` object.

## Usage

 ```1 2 3``` ```LIML(ivmodel, beta0 = 0, alpha = 0.05, manyweakSE = FALSE, heteroSE = FALSE,clusterID = NULL) ```

## Arguments

 `ivmodel` `ivmodel` object. `beta0` Null value β_0 for testing null hypothesis H_0: β = β_0 in `ivmodel`. Default is 0. `alpha` The significance level for hypothesis testing. Default is 0.05. `manyweakSE` Should many weak instrument (and heteroscedastic-robust) asymptotics in Hansen, Hausman and Newey (2008) be used to compute standard errors? `heteroSE` Should heteroscedastic-robust standard errors be used? Default is FALSE. `clusterID` If cluster-robust standard errors are desired, provide a vector of length that's identical to the sample size. For example, if n = 6 and clusterID = c(1,1,1,2,2,2), there would be two clusters where the first cluster is formed by the first three observations and the second cluster is formed by the last three observations. clusterID can be numeric, character, or factor.

## Details

`LIML` computes the LIML estimate for the instrumental variables model in `ivmodel`, specifically for the parameter beta. The computation uses `KClass` with the value of k = k_{LIML}, which is the smallest root of the equation

det(L^T L - k L^T R_Z L) = 0

where L is a matrix of two columns, the first column consisting of the outcome vector, Y, and the second column consisting of the endogenous variable, D, and R_Z = I - Z (Z^T Z)^{-1} Z^T with Z being the matrix of instruments. `LIML` generates a point estimate, a standard error associated with the point estimate, a test statistic and a p value under the null hypothesis H_0: β = β_0 in `ivmodel` along with a 1-α confidence interval.

## Value

`LIML` returns a list containing the following components

 `k` The k value for LIML. `point.est` Point estimate of β. `std.err` Standard error of the estimate. `test.stat` The value of the test statistic for testing the null hypothesis H_0: β = β_0 in `ivmodel`. `p.value` The p value of the test under the null hypothesis H_0: β = β_0 in `ivmodel`. `ci` A matrix of one row by two columns specifying the confidence interval associated with the Fuller estimator.

## Author(s)

Yang Jiang, Hyunseung Kang, Dylan Small

See also `ivmodel` for details on the instrumental variables model. See also `KClass` for more information about the k-Class estimator.

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10``` ```data(card.data) Y=card.data[,"lwage"] D=card.data[,"educ"] Z=card.data[,c("nearc4","nearc2")] Xname=c("exper", "expersq", "black", "south", "smsa", "reg661", "reg662", "reg663", "reg664", "reg665", "reg666", "reg667", "reg668", "smsa66") X=card.data[,Xname] card.model2IV = ivmodel(Y=Y,D=D,Z=Z,X=X) LIML(card.model2IV,alpha=0.01) ```

### Example output

```Warning messages:
1: In qT * sin(x)^2 :
Recycling array of length 1 in array-vector arithmetic is deprecated.
Use c() or as.vector() instead.

2: In qT * sin(x)^2/m :
Recycling array of length 1 in vector-array arithmetic is deprecated.
Use c() or as.vector() instead.

3: In (qT + m)/(1 + qT * sin(x)^2/m) :
Recycling array of length 1 in array-vector arithmetic is deprecated.
Use c() or as.vector() instead.

\$point.est
Estimate
[1,] 0.1640278

\$std.err
Std. Error
[1,] 0.05549507

\$test.stat
0
[1,] 2.955718

\$p.value
0
[1,] 0.003143776

\$ci
0.5 %    99.5 %
[1,] 0.02099074 0.3070648

\$k
 1.000409
```

ivmodel documentation built on Jan. 16, 2021, 5:28 p.m.