Corrected STA312 Assignment 10
Quiz in Tutorial Friday Nov. 23d
I had a mistake when I did this assignment. I made one of the variances zero by neglecting to mention it in the std statement. This caused by objective function to be way off. This has now been corrected below.
In the PIG study, farmers were asked some of the same questions on two occasions, one month apart. Two of the questions were Number breeding pigs on hand Sept. 1st, and Number of pigs farrowing (having babies) the following summer. So, we have 4 variables:
- Number pigs farrowing the following summer: Interview One
- Number pigs farrowing the following summer: Interview Two
- Number breeding pigs on hand Sept. 1st: Interview One
- Number breeding pigs on hand Sept. 1st: Interview One
This is the order of the variables in the data file
pig.data.
We will assume that measurement errors for the two interviews are independent, though this may be debatable.
We are interested in a regression where Number of breeding pigs on hand in September is the independent variable and Number of pigs farrowing is the dependent variable. Both the independent variable and the dependent variable are measured with error. We will treat this as a single-variable case of the double measurement design. Our primary objective is to estimate and test the regression parameter γ relating the latent independent variable to the latent dependent variable.
There is a new version of the paper on regression with measurement error. It's available
here. It now incorporates measurement error in the dependent variable, and you should find it helpful for this assignment.
- Look in the new draft of the paper on regression with measurement error, and hand-draw a diagram like Figure One, but with the names of the variables you will use in your SAS program.
- How do you know the model is identified? No proof is required; just answer in one or two sentences.
- Using proc calis with the cov and vardef=n options, fit the double measurement model to these data. Use bmi2.sas or bmi3.sas as a model. I predict that this will require you to sit and think a bit.
- For comparison, my final value of the objective function (after 6 iterations) is 0.0244994532. If you get this, everything else is be okay. Now please be ready to answer questions like the following:
- There is a chisquare test for how well the model fits (approximately a likelihood ratio test). Give the numerical value of the test statistic, the degrees of freedom, and the p-value. What does it tell you?
- Give the MLE of the regression parameter γ relating the latent independent variable to the latent dependent variable. The answer is a number from your printout.
- The double measurement model allows non-zero covariances between the measurement errors for the independent and the dependent variables (from the same interview). There are tests two such covariances on your printout. These tests are sensitive to the distribution of the latent variables and error terms (something that can't be checked), but still, please look at the two tests, determine whether they are statistically significant at the 0.05 level, and decide what they are telling you.
Please bring your log file and your list file to the quiz. Note that
the log file and the list file must be from the same SAS job.