UNIVERSITY OF CALIFORNIA, LOS ANGELES
Department of Economics

Economics 143 (Cameron) - Applied Regression Analysis

Classroom Handout #8a: Testing Joint Hypotheses: Joint Confidence Ellipses


When we are considering joint hypotheses about pairs of coefficients in a regression model, it is possible to extend the intuition of a confidence interval to two dimensions and to visualize the joint confidence ellipse geometrically. (For hypothese about three coefficients at one time, the analogous construct would be a three-dimensional ellipsoid, for more than three coefficients, the concept becomes hard to visualize, but we can test hypotheses in an equivalent manner by resorting to F-tests of joint significance.)
 |_* SHAZAM code downloaded from UCLA Econ 143 (CAMERON) WebSite:
 |_* HTML file called e143sh4.htm, and should have
 |_*  been downloaded as study.sha
 |_* example of omitted variables bias:  study time and midterm grade
 |_* midterm=percent score on midterm exam
 |_* study=hours spent studying for midterm in week before exam
 |_* gpa=proxy for quality of advance preparation for coursework

 |_sample 1 13
 |_read midterm study gpa
    3 VARIABLES AND       13 OBSERVATIONS STARTING AT OBS       1
Run a regression of MIDTERM on STUDY and GPA.
 |_ols midterm study gpa

 REQUIRED MEMORY IS PAR=     2 CURRENT PAR=   500
  OLS ESTIMATION
       13 OBSERVATIONS     DEPENDENT VARIABLE = MIDTERM
 ...NOTE..SAMPLE RANGE SET TO:      1,     13

  R-SQUARE =   0.9319     R-SQUARE ADJUSTED =   0.9182
 VARIANCE OF THE ESTIMATE-SIGMA**2 =   14.136
 STANDARD ERROR OF THE ESTIMATE-SIGMA =   3.7598
 SUM OF SQUARED ERRORS-SSE=   141.36
 MEAN OF DEPENDENT VARIABLE =   78.692
 LOG OF THE LIKELIHOOD FUNCTION = -33.9577


 VARIABLE   ESTIMATED  STANDARD   T-RATIO        PARTIAL STANDARDIZED ELASTICITY
   NAME    COEFFICIENT   ERROR      10 DF   P-VALUE CORR. COEFFICIENT  AT MEANS
 STUDY      5.1352     0.8352       6.149     0.000 0.889     0.9808     0.3363
 GPA        58.514      5.621       10.41     0.000 0.957     1.6605     2.5739
 CONSTANT  -150.32      23.27      -6.459     0.000-0.898     0.0000    -1.9102

Immediately after the OLS regression, issue a CONFID command, first for the coefficient on the STUDY variable (referred to by the variable it modifies). Note that the point estimate of the slope coefficient is in the middle of the row of numbers, the pair of 10% significance-level cutoffs is on either side, and the pair of 5% significance-level cutoffs is outermost. The output also gives the parameter standard error (which can also be seen in the second column of the regression output, and the 0.025 and 0.05 critical values of the relevant t-distribution.


 |_confid study
 USING 95% AND 90% CONFIDENCE INTERVALS

 CONFIDENCE INTERVALS BASED ON T-DISTRIBUTION WITH  10 D.F.
      - T CRITICAL VALUES =   2.228 AND   1.812
 NAME   LOWER 2.5%   LOWER 5%   COEFFICIENT   UPPER 5%   UPPER 2.5%   STD. ERROR
 STUDY      3.274       3.622       5.1352       6.649       6.996       0.835
Now issue a second CONFID command, this time for the coefficient on the GPA variable.

 |_confid gpa
 USING 95% AND 90% CONFIDENCE INTERVALS

 CONFIDENCE INTERVALS BASED ON T-DISTRIBUTION WITH  10 D.F.
      - T CRITICAL VALUES =   2.228 AND   1.812
 NAME   LOWER 2.5%   LOWER 5%   COEFFICIENT   UPPER 5%   UPPER 2.5%   STD. ERROR
 GPA        45.99       48.33       58.514       68.70       71.04       5.621

Now ask for a joint confidence ellipse, to assess plausible PAIRS of values for b2 and b3, as opposed to implausible values. (If the pair of values (0,0) lies within this confidence ellipse, we cannot reject the joint hypothesis that both slopes are simultaneously zero.) With a plain CONFID command, without a GNU option, you get a crummy dot-matrix plot.

 |_confid study gpa
 USING 95% AND 90% CONFIDENCE INTERVALS

 CONFIDENCE INTERVALS BASED ON T-DISTRIBUTION WITH  10 D.F.
      - T CRITICAL VALUES =   2.228 AND   1.812
 NAME   LOWER 2.5%   LOWER 5%   COEFFICIENT   UPPER 5%   UPPER 2.5%   STD. ERROR
 STUDY      3.274       3.622       5.1352       6.649       6.996       0.835
 GPA        45.99       48.33       58.514       68.70       71.04       5.621
 CONFIDENCE REGION PLOT FOR study    AND gpa
  USING F DISTRIBUTION WITH 2 AND   10 D.F.     F-VALUE =   4.100

 REQUIRED MEMORY IS PAR=     1 CURRENT PAR=   500
 FOR MAXIMUM EFFICIENCY USE AT LEAST PAR=     4
       205 OBSERVATIONS

Notice that the univariate confidence intervals are indicated by the + signs. Together, these two univariate confidence intervals form a "box." The joint confidence intervals, however, do not exactly cover the box. Some points that are inside the box (i.e. plausible values for each parameter taken individually) are outside the joint confidence ellipse (i.e. they are implausible pairs of values).


                    M=MULTIPLE POINT
    10.000        |
    9.5789        |
    9.1579        |
    8.7368        |
    8.3158        |
    7.8947        |
    7.4737        |                             * M*
    7.0526        |                        MM*M*    M
    6.6316        |     +              MMMM      + MM
    6.2105        |                *MMM           MM
    5.7895        |              MMM            MMM
    5.3684        |           MMM             MMM
    4.9474        |         MM*      *      MMM
    4.5263        |      *MM             MMM
    4.1053        |     MM            *MM*
    3.6842        |   MM           MMMM
    3.2632        |  MM +      *MMM*             +
    2.8421        |  M     M*MM*
    2.4211        |  **M **
    2.0000        |
                   ________________________________________

              40.000    50.000    60.000    70.000    80.000

                                GPA

For a crisp line-plot of the confidence ellipse, Shazam for Windows makes it easy to display a gnuplot in the context of running the program. Here, I have added commfile= and datafile= options so that I can save the gnuplot for later modification.


 |_confid study gpa / gnu lineonly commfile=conf.gnu &
 |    datafile=conf.dat
 USING 95% AND 90% CONFIDENCE INTERVALS

 CONFIDENCE INTERVALS BASED ON T-DISTRIBUTION WITH  10 D.F.
      - T CRITICAL VALUES =   2.228 AND   1.812
 NAME   LOWER 2.5%   LOWER 5%   COEFFICIENT   UPPER 5%   UPPER 2.5%   STD. ERROR
 STUDY      3.274       3.622       5.1352       6.649       6.996       0.835
 GPA        45.99       48.33       58.514       68.70       71.04       5.621
 CONFIDENCE REGION PLOT FOR study    AND gpa
  USING F DISTRIBUTION WITH 2 AND   10 D.F.     F-VALUE =   4.100

 REQUIRED MEMORY IS PAR=     1 CURRENT PAR=   500
 FOR MAXIMUM EFFICIENCY USE AT LEAST PAR=     4
       205 OBSERVATIONS
  SHAZAM WILL NOW MAKE A PLOT FOR YOU
  NO SYMBOLS WILL BE PLOTTED, LINE ONLY

 ..INPUT FILE COMPLETED..TYPE A NEW COMMAND OR TYPE: STOP
 TYPE COMMAND

Here is a screen shot of what you see when you ask for a gnuplot of the joint confidence ellipse. Does it look like the pair of values (0,0) is inside the ellipse? Therefore, is H0: b2=b3=0 a plausible hypotheses? Could it be that neither study time nor gpa has any effect on midterm score?


Updated: 2:23 PM 10/28/98; Prepared by: Trudy Ann Cameron Site Index