The heteroscedasticityconsistent covariance matrix estimator (HCCME), also known as the sandwich (or robust or empirical) covariance matrix estimator, has been popular in recent years because it gives the consistent estimation of the covariance matrix of the parameter estimates even when the heteroscedasticity structure might be unknown or misspecified. White (1980) proposes the concept of HCCME, known as HC0. However, the smallsample performance of HC0 is not good in some cases. Davidson and MacKinnon (1993) introduce more improvements to HC0, namely HC1, HC2 and HC3, with the degreesoffreedom or leverage adjustment. CribariNeto (2004) proposes HC4 for cases that have points of high leverage.
HCCME can be expressed in the following general “sandwich” form:

where , which stands for “bread,” is the Hessian matrix and , which stands for “meat,” is the outer product of gradient (OPG) with or without adjustment. For HC0, is the OPG without adjustment; that is,

where is the sample size and is the gradient vector of th observation. For HC1, is the OPG with the degreesoffreedom correction; that is,

where is the number of parameters. For HC2, HC3, and HC4, the adjustment is related to leverage, namely,

The leverage is defined as , where is defined as follows:
For an OLS model, is the th observed regressors in column vector form.
For an AR error model, is the derivative vector of the th residual with respect to the parameters.
For a GARCH or heteroscedasticity model, is the gradient of the th observation (that is, ).
The heteroscedasticity and autocorrelationconsistent (HAC) covariance matrix estimator can also be expressed in “sandwich” form:

where is still the Hessian matrix, but is the kernel estimator in the following form:

where is the sample size, is the gradient vector of th observation, is the realvalued kernel function, is the bandwidth parameter, and is the adjustment factor of smallsample degrees of freedom (that is, if ADJUSTDF option is not specified and otherwise , where is the number of parameters). The types of kernel functions are listed in Table 8.2.
Table 8.2: Kernel Functions
Kernel Name 
Equation 

Bartlett 

Parzen 

Quadratic spectral 

Truncated 

TukeyHanning 

When you specify BANDWIDTH=ANDREWS91, according to Andrews (1991) the bandwidth parameter is estimated as shown in Table 8.3.
Table 8.3: Bandwidth Parameter Estimation
Kernel Name 
Bandwidth Parameter 

Bartlett 

Parzen 

Quadratic spectral 

Truncated 

TukeyHanning 

Let denote each series in , and let denote the corresponding estimates of the autoregressive and innovation variance parameters of the AR(1) model on , , where the AR(1) model is parameterized as with . The factors and are estimated with the following formulas:

When you specify BANDWIDTH=NEWEYWEST94, according to Newey and West (1994) the bandwidth parameter is estimated as shown in Table 8.4.
Table 8.4: Bandwidth Parameter Estimation
Kernel Name 
Bandwidth Parameter 

Bartlett 

Parzen 

Quadratic spectral 

Truncated 

TukeyHanning 

The factors and are estimated with the following formulas:

where is the lag selection parameter and is determined by kernels, as listed in Table 8.5.
Table 8.5: Lag Selection Parameter Estimation
Kernel Name 
Lag Selection Parameter 

Bartlett 

Parzen 

Quadratic spectral 

Truncated 

TukeyHanning 

The factor in Table 8.5 is specified by the C= option; by default it is 12.
The factor is estimated with the equation

where is 1 if the NOINT option in the MODEL statement is specified (otherwise, it is 2), and is the same as in the Andrews method.
If you specify BANDWIDTH=SAMPLESIZE, the bandwidth parameter is estimated with the equation

where is the sample size; is the largest integer less than or equal to ; and , , and are values specified by the BANDWIDTH=SAMPLESIZE(GAMMA=, RATE=, CONSTANT=) options, respectively.
If you specify the PREWHITENING option, is prewhitened by the VAR(1) model,

Then is calculated by

The bandwidth calculation is also based on the prewhitened series .