Question

In: Statistics and Probability

What do you put into STATA to test residuals for positive first order serial correlation?

What do you put into STATA to test residuals for positive first order serial correlation?

Solutions

Expert Solution

Serial correlation is a frequent problem in the analysis of time series data. Various factors can produce residuals that are correlated with each other, such as an omitted variable or the wrong functional form. If the problem cannot be resolved by improved model specification, then we need to correct for the influence of the autocorrelation through statistical means.

The basic steps are :

  • Set the data set to be a time-series data set
  • Run regression
  • Examine for serial correlation
  • Correct the regression for the serial correlation

    Set the data set to be a time-series data set

    Stata needs to know that the data set is a time series data set. Use the TSSET command.

    First, create a time variable. Sinvce we have quartely data, and only ear and quarter as variables, we need to create a variable coded 1,2,...,t for the quarters in the data set. Use the Generate command,

    gen time = (year - 1949)*4 + quarter

    Examine this data with the list command to ensure that it is the series 1 to 148 indicateing that there are 148 quarters in the period 1949-1985.

    Now set this as the time variable

    tsset time , q

    Note that if you examine the data with the

    tsset

    command, the quarterly dating is off. Stata starts all data sets on at january 1960. This can be alterd, but not here!


    Run the regression analysis

    Regress Presidential approval on real GNP

    reg approval realgnp


    Examine for serial correlation

    After running the regression, type the Durbin-Watson Statistic command.

    dwstat


    Correct the regression for the serial correlation

    Correcting for autocorrelation is easy with STATA. Run the analysis with the Prais-Winston command, specifying the Cochran-Orcutt option.

    prais approval realgnp, corc

    This gives us results that are substantially different from the original results.

    Note the following points in the estimation:

  • the number of iterations
  • the final value for rho
  • the difference in the estimates (both coefficients and t-values)
  • the change in r-square
  • the transformed Durbin-Watson
  • Additional Information on Stata commands. (Taken from the Stata help information)



    For additional information about how Stata treats time series data, here is the Stata help for TSSET

    The Stata information on Prais-Winston estimation options.


Related Solutions

Correlation - Do you think there would be a positive correlation between a placement test score...
Correlation - Do you think there would be a positive correlation between a placement test score and the final grade in this statistics class? What other variables do you think would have a positive correlation with the final grade in this (or any) class? What variables would have a negative correlation with a final grade in a class? Look up a study that finds a correlation between grades and some other variable. Describe the variables, the study, the methods used,...
When using the LM test for serial correlation, what is the null hypothesis? Select one: a....
When using the LM test for serial correlation, what is the null hypothesis? Select one: a. No serial correlation is present. b. It depends on the model specification. c. Statistically significant serial correlation with the first lag. d. Statistically significant serial correlation with unspecified lag.
Use Statistical Tables to test for serial correlation given the following Durbin-Watson d statistics for serial...
Use Statistical Tables to test for serial correlation given the following Durbin-Watson d statistics for serial correlation. Draw a picture for hypothesis testing. State your hypothesis. i. d=0.62, K=2, N=21, 5-percent, one-sided positive test ii. d=3.89, K=3 N=18, 5-percent, one-sided positive test iii. d=1.31, K=4, N=36, 5-percent, one-sided positive test
Use Statistical Tables to test for serial correlation given the following Durbin-Watson d statistics for serial...
Use Statistical Tables to test for serial correlation given the following Durbin-Watson d statistics for serial correlation. Draw a picture for hypothesis testing. State your hypothesis. d=0.62, K=2, N=21, 5-percent, one-sided positive test d=3.89, K=3 N=18, 5-percent, one-sided positive test d=1.31, K=4, N=36, 5-percent, one-sided positive test d=1.19, K=2, N=85, 5-percent, one-sided positive test d=1.29, K=4, N=23, 5-percent, one-sided positive test
Suppose you run a regression and the Serial Correlation LM Test, has a p-value of 0.0000....
Suppose you run a regression and the Serial Correlation LM Test, has a p-value of 0.0000. How would you interpret the results using an F-test?
a. Draw a scatter plot. Is this a positive or negative correlation? Explain what a positive correlation and negative correlation are. b.Compute the pearson correlation.
 For the following scores, x y 0 4 2 9 1 6 1 9 a. Draw a scatter plot. Is this a positive or negative correlation? Explain what a positive correlation and negative correlation are. b.Compute the pearson correlation.
10) What test should you run to determine if your residuals are not spatially dependent (i.e....
10) What test should you run to determine if your residuals are not spatially dependent (i.e. they are independent)? If that test proves to be significant, what corrective action can you take?
I put together a scatterplot of Ice Cream Sales v Temperature. It is a positive correlation....
I put together a scatterplot of Ice Cream Sales v Temperature. It is a positive correlation. What are possible lurking variables?
Why do you think we see a positive correlation between adherence to an ESG framework and...
Why do you think we see a positive correlation between adherence to an ESG framework and firm financial performance? Is there causality? Which way does it flow?
Define these functional group tests, What does the test do and what do positive results look...
Define these functional group tests, What does the test do and what do positive results look like? ex) Lucas test- differentiates primary, secondary, and tertiary alcohols. This cannot be used on large alcohols. ex) Bromine test- Tests for the presence of multiple bonds If added to an alkene or alkyne the brown color will disappear If added to an alkane it will remain brown Periodic acid- Tollens test- 2,4-Dinitrophenylhydrazine- Sodium bisulfite addition- Iodoform test- hinsberg test- Sodium hydroxide- Hydroxamate test-...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT