elem econ homework
Regression inference
Distribution of OLS estimators
Recall the multiple regression model:
Our goal is to conduct hypothesis tests on one or more of the regression coefficient estimates, but in order to do so we must know what the sampling distribution of the OLS estimator is.
The OLS estimates are functions of sample outcomes of the dependent and independent variables and of the error term
Up until now we have only made assumptions about the mean and variance of the error term, but we haven’t made a stand on what the distribution should be…
Assuming normal errors
In order to conduct hypothesis tests we add one more assumption to the 5 Gauss-Markov assumptions.
Assume that the population error e is independent of all of the regressors and that
This is a particularly strong assumption.
Not only are we assuming that we know the mean and variance of the unobserved component of the regression, but now we assume we know the entire distribution.
Moreover, this assumption actually implies the zero conditional mean and homoskedasticity assumptions.
In the context of cross-sectional regression the 5 Gauss-Markov assumptions combined with the above assumption are called the classical linear model (CLM) assumptions.
Visualizing normal errors
BLUE minus L
With the normality assumption in place we can actually make a somewhat stronger statement about how precise the OLS estimator is relative to other estimators.
Specifically under the classical linear model assumptions, OLS is the best unbiased estimator
Recall that best means minimum variance.
So now we can say that the OLS estimator has the smallest variance among all unbiased estimators, not just among linear unbiased estimators.
That’s all well and good, but we should bear in mind that we are making some pretty strong assumptions. It is often quite difficult to satisfy these assumptions in practice. After all the zero conditional mean assumption implies no omitted variable bias. As we discussed before, in the absence of random assignment we can never even be fully sure that we have no OVB.
Normal distribution of OLS
Under the CLM assumptions, conditional on the sample values of the independent variables,
Where
The normality should come as no surprise. After all, is a linear combination of the individual error terms. We have assumed that we have a random sample from the population, and that the population error term is normally distributed. This buys us i.i.d. error terms, so is a linear combination of i.i.d. normal random variables (which we have discussed is itself normally distributed).
Given this result, it directly follows that by definition of a standard normal distribution. This is important for hypothesis testing.
The t distribution for estimators
One of the most important types of hypothesis testing in regression is a hypothesis test about a single population parameter. Of course, we do not usually know the exact standard deviation of the regression estimate, so we use the standard error.
When we substitute the standard error, we get the following result:
We won’t formally prove this result, but we can rewrite the above as the ratio of a standard normal random variable and a chi-squared random variable with (n-k-1) degrees of freedom, which is where the t distribution with (n-k-1) degrees of freedom comes from.
The null of a null effect
The primary hypothesis test that we are often interested in involves the following null hypothesis for a single regression coefficient:
Recall that under the CLM assumptions, measures the true partial effect of the j-th regressor on the dependent variable. So this type of hypothesis test is tantamount to asking whether that particular regressor has no effect on the dependent variable.
This is important since an estimate of the regression coefficient is a random variable, so a non-zero estimate is not strictly speaking evidence of an actual non-zero effect (in fact estimates will virtually always be non-zero).
The null of a null effect
For example consider again the regression equation: .
The null hypothesis means that after controlling for experience, additional education has no effect on wages.
Or consider the regression:
Where famheart is an indicator for family heart disease history.
The null hypothesis means… (you fill in the blank)
The t statistic for
The t statistic for the standard null hypothesis is easy to calculate. We simply take the ratio of the regression estimate to the standard error:
For example, recall the miles-per-gallon on car weight regression we ran before from the “mtcars” dataset in R:
Running that regression we get the following information: and .
Now’s a good time to recall how to get that info in R…
Thus the t statistic for is
I’m sure you’re excited for the result of the hypothesis test, but first we need to establish a rejection criteria…
Testing against one-sided alternatives
In order to establish the rejection criteria for the hypothesis test, we first need to decide on the alternative hypothesis we wish to use.
Suppose continuing on from the previous mpg on weight example, we are only interested in whether or not heavier cars have lower miles-per-gallon. In this case the relevant alternative hypothesis is given by:
In practice under the given alternative hypothesis above, we are really testing , but if we reject the null of in favor of the above alternative then we automatically reject . So the simple form of the null suffices.
Testing against one-sided alternatives
Next we need to decide on a significance level. Remember there is no “correct” significance level to use, but the most common choices in econometrics are . Suppose for our case we wish to use a 5% significance level. Also suppose we only have 20 observations (in actuality there are 32 in the dataset, but use your imagination). Then we need to find the critical value from the t table associated with a one-tailed test with 18 degrees of freedom at a 0.05 significance level. This value is -1.734 (negative because we are using a left-tailed rejection rule).
Testing against a one-sided hypothesis
The rejection rule in our imaginary case where we have 20 observations for our simple regression is shown to the right. We will reject the null hypothesis if we get a t statistic that is less than -1.734.
Our t statistic is -9.559, so we reject the null at a 5% significance level.
Testing against a one-sided alternative
If instead we wished to test against the alternative , then we would have a critical value of 1.734, and our rejection criteria would be to reject for any t statistics greater than 1.734. If this were the case, we would of course fail to reject the null at a 5% significance level.
Another important thing to note is that as we jack up the sample size (and thus the df), the t distribution becomes closer and closer in shape to a standard normal distribution. In fact the t distribution limits to a standard normal as we take n to infinity. In light of this, it is common practice among econometricians to use critical values from the z table for df>120.
Testing against a two-sided alternative
We are often interested in whether or not the regression parameter differs from 0 in either direction. In this case we are simply asking whether or not the regressor has any effect on the dependent variable.
The relevant alternative hypothesis in this case is .
We will use a two-tailed rejection rule with two (symmetric) critical values. We will reject the null if our test statistic satisfies . Where is the relevant positive critical value for a two-tailed test with significance level α.
Testing against two-sided alternatives
Let’s stick with a 5% significance level, and suppose we have 27 observations. Then we find the critical value associated with a 2-tailed test a 5% significance level with 25 degrees of freedom. This critical value is 2.060. For a two-tailed test we are looking for the critical value associated with 2.5% tail probability (so that both tails add up to 5%)
Testing against a two-sided alternative
So our rejection rule is to reject the null if t<-2.06 or t>2.06. Our t statistic is t=-9.559, so we once again reject the null at a 5% significance level.
A little note about econometric language: When we reject the null at a particular significance level for a particular regressor X, we say that “X is statistically significant (or statistically different from zero) at the 5% level.”. If on the other hand we fail to reject the null, we would say that X is statistically insignificant.
Common critical values from the z table
As previously mentioned, it is common practice in econometrics to use critical values from the z table for degrees of freedom exceeding 120. We also commonly use the 0.10, 0.05, and 0.01 significance levels, so it is useful to know the associated critical values for those significance level from a z table.
For a one-tailed test those critical values are, respectively. 1.282, 1.645, and 2.326
For a two-tailed test those critical values are 1.645, 1.96, and 2.576
I won’t make you memorize those, but you can see that if we have t statistics above 2 (and sufficiently large df) then we have statistical significance at some level.
Other hypotheses about
There may be some cases in which we are interested in seeing whether or not is equal to some other value than zero. Suppose that we wished to test whether or not is equal to some non-zero constant a. Then the relevant null hypothesis is given by .
We can calculate the test statistic in this case as
We can write a general test statistic as follows: . So that we can see that the test statistic is telling us how many standard deviations the estimate is from the hypothesized value.
Other hypotheses about
For example, an interesting question in labor economics is whether or not increasing minimum wages actually decreases employment. We know classical economic theory unequivocally predicts decreasing employment in response to (binding) minimum wage increases, but the empirical evidence is far from in consensus on the matter.
We could test this by estimating the elasticity of employment with the following regression equation: . In this regression equation has the interpretation of the elasticity we seek (you don’t need to know why, but for the curious recall that changes in logs are related to changes in percentages).
Suppose we believe that the elasticity is -1, so that a 1% increase in the minimum wage is associated with a 1% decline in employment. In this example, the relevant null hypothesis is , and the test statistic would be calculated as
Other hypotheses about
We next establish an alternative hypothesis. This does not differ substantially from the zero effect case, we just set the alternative relative to the hypothesized value instead of zero (-1 in this case). For example a two-sided alternative for the minimum wage example would look like:
The remainder of the procedure for testing other hypotheses about is identical to the case when we were testing for a zero effect. We still select a significance level, find critical values based on the significance level and degrees of freedom, and establish our rejection rule.
p-values for t tests
There is some measure of arbitrariness to classical hypothesis testing. After all, there is no right significance level to choose, so researchers using the exact same data can draw two different results if they have differing opinions on which significance level to use.
Thus instead of testing at different significance levels, it may be informative to ask: “what is the smallest significance level at which the null hypothesis could be rejected based on the observed value of the t statistic?”. This level is called the p-value for the test.
The p-value is the significance level of the test if we were to use the calculated test statistic as the relevant critical value.
p-values for t tests
For example, suppose we calculate t=1.85 from a regression with 40 degrees of freedom, and that we are using a two-sided alternative. In order to calculate the p-value we would need to find the tail probability associated with a value of (+ and -) 1.85 from a t distribution with 40 df.
This is illustrated in the table to the right. In this case, for a two-sided alternative, the p-value is 0.0718
Interpreting p-values
With a given p-value in hand, we can determine for what significance levels we can reject the null.
For a given significance level α, we reject the null at the level if p-value< α.
So for our example we would reject the null at the 10% level, but not at the 5% or 1% levels.
One way to think about what the p-value represents is the probability of observing a t statistic as large as we did if the null hypothesis is true.
So in general, smaller p-values provide stronger evidence against the null hypothesis, which in the case of a zero-effect null is favorable.
Calculating p-values
Unfortunately, t tables are not generally detailed enough to provide p-values for all values of test statistics, so we usually resort to statistical software to calculate the p-value for us.
The good news is that most statistical software packages automatically calculate the p-values for a zero-effect null with a two-sided alternative for each regression coefficient (as well as the corresponding test statistic). If we wish instead to use the p-value for a one-sided alternative, we can simply divide the reported p-value by 2.
However, if we wish to test a different hypothesis, such a p-value is not reported automatically, so we would have to calculate it separately.
Calculating the relevant test statistic is at least easy given the estimate and the standard error.
Economic vs. statistical significance
Statistical significance is a wonderful thing, but we should take care in interpreting statistical significance as evidence that a regressor has an “important” effect on the dependent variable. Recall that the test statistic for the null hypothesis is given by . So our test statistic can indicate statistical significance either because is “big” or because is “small”. We should also think of the economic (or practical) significance.
For example, returning to the minimum wage example, suppose we got an estimate of the elasticity of with a standard error of 0.000001. Then our test statistic would be t=-20, which would definitely result in statistical significance at all conventional levels. However, a closer look at the size of the estimate reveals the prediction that a 1% increase in the minimum wage only decreases employment by 0.00002%. So while this result is statistically significant, it does not seem to be practically important.