Enhancing Implementation Science- 12 -Department of Veterans Affairs

**Department of Veterans Affairs**

**HERC Econometrics with Observational Data**

**Cyberseminar 05-0902012**

**Cost as the Dependent Variable (Part 2)**

**Paul G. Barnett**

Paul G. Barnett:  I’m going to talk today in the second part of our presentation about how to conduct econometric analysis when a cost is your dependent variable.  This is continued from what we discussed last time.  

First, to start with a brief review of the Ordinary Least Squares regression model, the classic linear model that hopefully you’re familiar with.  It would make some strong assumptions to run this model; we make the assumption that the dependent variable can be expressed as a linear function of some independent variables, and in this case it’s represented by the Xi.  This linear function is the intercept alpha and a parameter, the alpha-beta estimated and something left over, the residual or the error term represented by that epsilon.  The Ordinary Least Squares makes five assumptions; first, that the expected value of that error term is zero and that the errors from different observations are independent of each other, that they have identical variants; they have normal distribution, and they’re not correlated with the Xs, with the independent variables in the model.  What econometrics is about really is how do you cope with any of these assumptions not being true?  

Then the cost data turns out is a difficult variable where some of these assumptions don’t work out.  So costs are skewed by some rare but extremely high-cost events, those very expensive hospital stays that only a few patients have.  The other problem is that the cost is truncated on the left hand of the distribution by some enrollees, people who don’t incur any cost at all.  Then also cost, there’s no negative value; that distribution is also limited in that sense.  So it’s not a normal variable.  If we ran an Ordinary Least Squares regression on cost data, we could end up with a model that would predict negative cost.  And of course that doesn’t make sense when costs are bounded by zero.

Last time we talked about how transforming costs by taking the log of cost can make the variable more normal.  Of course, there are some limitations of the log transformation approach.  The first is the predictive cost is affected by retransformation bias.  We talked about how we can use the smearing estimator to handle that, and I refer you to those slides about how to determine the smearing estimator which is, in words, the mean of the exponentiated residual.  The Ordinary Least Squares on log costs assumes that there’s a constant error, that is, homoscedasticity.  What we’re going to get to today is what to do when that assumption, that there’s a constant error, is not true.  That is, there is heteroscedasticity.  We’ll also talk about what to do when there are many zero values in the data set.  How can you do a test that doesn’t rely on any assumptions about the distribution of the cost data?  And finally, how to determine which of these methods is the best one to use.

The first question is, what do we do when there’s heteroscedasticity?  Let’s explain what we mean by heteroscedasticity.  Homoscedasticity is that assumption of identical variants, that every error term has an identical expected variance.  Heteroscedasticity is, somehow the variance depends on the independent variable or on the prediction of Y, and that Y, our dependent variable in this case, is cost.  A picture sometimes is worth a thousand words, so here’s the picture of homoscedasticity.  In this case, the X axis in this plot is cost; this is some idea about what the variants might be.  It doesn’t vary with cost.  Then the picture of heteroscedasticity, you can see that the variance is somehow related to the X axis, that the farther right on the X axis you go, the greater the variance.  Heteroscedasticity is something that is likely to occur in cost data, and it’s probably not such a good idea to make that assumption of homoscedasticity.  So why do we worry about that?  If we do an Ordinary Least Squares like our Ordinary Least Squares of the transformed cost, and then we do the retransformation to predict cost, that estimate could be really biased.  Manning and Mullahy write that it reminded them of the nursery rhyme written by Longfellow that, “When she was good, she was very, very good.  But when she was bad, she was horrid.”  So the idea that in some cases when you do have heteroscedasticity you can get really bad predictions.  

What’s the solution?  It is a generalized linear model.  The generalized linear model relies on a link function; the link function, this g(), is something that encompasses the regression.  Then we specify really two things; along with the link function we also specify a variance, a function.  And I refer you to Manning and Mullahy’s paper in the *Journal of Health Economics* in 2001 as being the key reading about this.  But we’ll now explain how this GLM works in cost data.  Here is the link function; so the link function is this G in red.  Before we were estimating the expect value of Y conditional on X; that is, estimated value of cost conditional on our independent variables that explain cost at some function of linear function alpha plus data times RX, or maybe it’s many Xs that are in the model.  The link function could take many forms; it could be the natural log, which we talked about a log transformation last time.  It could be square root.  

There are other functions that could be used as a link function.  So instead of using G, we’re taking in this case a natural log of the expected value of cost conditional on the independent variables.  This is the specification of link function in the GLM model.  Then just as before, when we used natural logs in the Ordinary Least Squares, data has a nice interpretation, which is it represents the percent change in Y for a unit change in X.  It really has that same interpretation.  So why go to this trouble of a GLM?  Well, it’s a little bit different from OLS, and it doesn’t have that assumption of homoscedasticity.  Also note here that the Ordinary Least Squares of the log cost, the expression is of expected value of the log cost conditional on X whereas in GLM, it’s the log of the expected value.  The first is the expectation of log and the next is log of expectation, and they’re not the same thing.  The advantage of this is with GLM, if we’re interested in finding predicted Y or predicted cost, we don’t have the problem of retransformation bias.  So we don’t use the smearing estimator.  

GLM also allows us to accommodate observations that have zeros in them.  That is, the cost is equal to zero, which is something we can’t do with the Ordinary Least Squares.  As a consequence, there are those two advantages of this GLM along with the relaxation of the assumption that all of the [variables that] errors have are homoscedastic.  That is, that they have equal variance.  Now, we mentioned that not only do we have to specify a link function, but we have to specify a variance function.  GLM does not assume constant variance; in fact, it assumes that there is some sort of function that explains the relationship between the variance and the mean, that the variance in Y, in this case cost, is somehow conditional on the independent variables.  

There’s a bunch of possible variance functions.  Two of the most popular ones are a gamma distribution, that variance is proportional to the square of the mean and somehow a function of that, and Poisson as a variance is actually proportional to the mean.  These are assumptions.  But they’re also something that we can test, which assumption is most appropriate.  That’s the second part of it; the first is we have to decide what our link function is going to be for GLM, and the second is we have to decide what our variance function is going to be.  Now, here is the practical advice.  How do you specify this in some of the common statistical packages?  In this case, we’re giving an example that we have a dependent variable Y; that’s our cost.  And we have explanatory variables: X1, X2, X3.  In Stata we use the GLM command.  Y is the dependent variable as a function of these three independent variables.  In this case, I’m specifying the distribution function or the distribution family, FAM, as gamma and the link function as log.  

There are other ways to specify.  I could specify family as Poisson; I could specify link as square root.  There are lots of possibilities.  In SAS, there is entirely similar syntax, which is done with a PROC GENMOD command.  As you can see in this example, we have our model Y as a function of the Xs.  Then we put the forward slash and then specify our options.  Our distribution is gamma and our link is log.  These are entirely equivalent statements.  But I’m going to issue the warning that SAS does not play well when you have zero-cost observations in the data set.  This is why I would say if you have zero-cost observations, you really can’t use SAS.  I have not asked the SAS folks about this; they think this is the way it should be done.  [Inaudible] asked Will Manning about it; he said that’s definitely wrong.  And I don’t see any way to program easily around this in SAS.  So that’s just the warning.  The last time I gave this course I wasn’t aware of this problem.  But you probably want to use Stata if you’re going to have any observations that have zero cost, and you definitely do.  Plus, there are just a few.  It gives quite different results when you drop those zero costs, obviously.

I mentioned some of the advantage of using a general linear model over an Ordinary Least Squares of the log variable.  We mentioned that GLM doesn’t make the assumption of homoscedasticity, so it allows some correction for the problems of heteroscedasticity.  It doesn’t lead to retransformation; it accommodates, so you don’t have to use a smearing estimator and make any assumptions to predict cost out of your model.  Then it allows you to have zero-cost observations.  Now, there is an advantage of using Ordinary Least Squares with the log transform.  If none of these other things are problems, it’s more efficient; that is, it has smaller standard errors than are estimated with a general linear model.  So it does have that advantage, but you have to make some strong assumptions in order to gain that efficiency.

Now, which link functions?  I mentioned the link function could be log, but it could be square root.  It could be other forms.  You can estimate what the link function is by doing a Box-Cox regression.  So that left in this cost of the theta minus one divided by theta is the Box-Cox transform.  What we’re trying to do with this Box-Cox regression is estimate theta, and theta will tell us what our link function needs to be.  If we run the Box-Cox command with cost as our dependent variable and then we put in whatever independent variables we’re planning to use in the model, then it will give us our information about theta, which will inform us about our link function.  And we, in this case, exclude any values—it should say if cost is greater than zero; that is, we can’t put zeros in this Box-Cox regression.  One wonders if there’s an appreciable number of zeros, whether we’re exactly getting it right.  But this is the way to estimate the link function.  These are the potential link functions that we might use: an inverse log, square root, cost, or cost squared.  So cost would be just the Ordinary Least Squared, untransformed cost.  These are how we would transform the dependent variable to run our regression, run our GLM regression, in essence by choosing a link function.  Which link function should we use?  As a practical matter I must say that my experience with this running with healthcare costs is that it usually comes out either the log or the square root; something that is not quite as skewed as a log may actually only need to have a square root link function.  But log is more common.  We’ll show an example of how we estimate this.

We chose our link function, and then we also need to decide which variant structure.  This GLM family test, or modified Park test, is a way to do this.  We run an initial general linearized model.  We find the residuals; that is, the difference between the predicted value of cost and the actual cost.  We square those, and then we run a second regression with the predicted value as the independent variable.  If you look at the bottom of this, you see that regression of the difference in the residual from the actual to predicted squared is a function of—and this is the residual.  We’re interested in that gamma-one parameter there.  We want to predict that gamma one.  That gamma one value tells whether we should be using a normal distribution.  If gamma one is equal to one, then we would choose the Poisson family distribution.  To gamma three we’d use the Wald, or the inverse normal distribution.  Basically this gamma parameter allows us to say what distributional assumption we should make, what variance function should we choose.

Before I go on to these other models, what I’d like to do is give an example with using Stata.  I’m going to select these code lines here.  This is some data that came from a paper that we published two years ago in the *Journal of Substance Abuse Treatment* from a study of looking at programs that do methadone maintenance, opiate substitution.  So in this first set, I have just used the data from the [most] study.  This is the exact same data set that we used in the last seminar’s examples.  Now that I’ve used this data, you’ll see here on the left that these are the variables in the data set.  [Concord] is this patient from a program that is highly concordant with opiate substitute and treatment guidelines.  We have some other variables over here; do they HIV/AIDS?  Hepatitis C?  Schizophrenia?  What was their total cost that they incurred?  That’s our data set, very simple data set.  We’re interested in saying, “Did the concordant programs,” those that were concordant with treatment guidelines, “have higher cost once you consider differences in some of these case-mixed variables?”

Last time we did this, we did a log transformation.  This is the Stata command on generating a new variable called Log of All Cost by simply taking the log of all cost variables.  Stata has done that.  Now, I’ll just summarize the variables in our data set; all cost, the mean cost here, $21,000.  The log of all costs is about 9.5.  This concord is a zero-one variable.  Are they in a highly concordant or less concordant program?  So one means a program that’s highly concordant with treatment guidelines.  HIV variable is, did this patient have HIV/AIDS?  Did this patient have schizophrenia?  So that’s our data set.  Now, we’ll just run an Ordinary Least Squares model.  Log cost is a function of that concordant—concordance with treatment guidelines and the indicators for these conditions: HIV/AIDS and schizophrenia.  Now, here we see that concordance with guidelines leads to about twenty-six percent, twenty-seven percent higher costs.  The T value here is statistically significant, different from zero.  

This is the result from SAS, the SAS listing that we ran last time.  You can see here that our intercept and our parameters—our intercept here was 9.3267, so it’s exactly the same parameter.  2.2 is the T value—excuse me, 287 or .023--.029.  So this is exactly the same results of SAS data.  It’s very reassuring that the programs give us the same thing when we do Ordinary Least Squares log cost.  Now, we want to try a GLM model, and the first thing I’ll do is run the Box-Cox regression.  Box-Cox is coming up with theta equals .18.  If theta is .8—what did I say?  .18 is close to 0; that is, that log transformation is the one we ought to use, the log link function.  Let’s go back to our Stata program here, and actually the Box-Cox regression will test here the hypothesis that theta’s close to negative one; theta’s close to zero, and theta’s close to one.  This is saying theta’s really far from negative one; it’s far from one.  It’s significantly different from zero, but this [inaudible] statistic’s small.  So it’s not so very different from zero.  This is saying, “Use the log link function.”  That’s what we get out of our Box-Cox.

So now, we try a GLM model.  The first test is with a gamma distribution, and we’ll use this gamma distribution assumption in order to generate our gamma family test; that is, to test which is the right distribution.  And we’re going to do it with this log link function.  So have Stata run this analysis, and we end up with a regression that’s quite similar. Let’s bring back our value from before when we did Ordinary Least Squares.  You see that the concord parameter is now a little bit higher, and our T value is actually a little bit more significant, but for the HIV/AIDS is not significant.  Before it was just [fail] significant.  So there are some slight changes by relaxing this assumption and using this different model.  Schizophrenia parameter’s longer significant whereas before it was significant.  The parameters are similar but not the same, both in terms of the point estimate, the co-efficient here, and also the standard errors.  The standard errors are sometimes larger, sometimes smaller.

Moderaor:  We have a relevant question.  Someone is asking, “What do I do if I get a theta of .25?”

Paul G. Barnett:  Well, you can test.  In theory, it’s going to be closer to one or the other.  It’s probably not going to matter too much what you use.  And if it does, then you have to kind of scratch your head a little bit about which is the best.  There is another more flexible form, which I will briefly mention, that basically allows you to use theta as .25 and not choose one or the other.  But that’s the next slide in the presentation.

So let’s just do the modified Park test here.  This is also called the GLM family test.  We’re going to predict our fitted value, finding the log value of that fitted value.  Then we’re going to estimate our residuals, which is the difference between our actual and our fitted cost.  Then we’re going to square the residuals.  Those are those steps that we’re talking about.  Then we run another GLM where we estimate, take our squared residuals; that’s this R2.  That was a residual squared; we use the log of the fitted value to predict them.  And we get this coefficient of 1.6.  

Let’s go back to our slide here, and here’s “What do we do with a 1.6?”  Well, that’s closer to gamma than plus R.  It’s not quite two, but it’s closer to two than it is to one.  So the gamma turns out to have been a good model to have chosen.  Let’s just go back to our Stata job here; we can also test these very specific commands.  This was the gamma parameter.  Is it closer to zero, one, two, or three?  This is the value here; the P value here is the largest.  We’re saying that we’re making the least bad assumption by assuming that parameter for choosing the distribution family is two; that is, that it’s the gamma distribution.  I realize I’ve introduced a little bit of confusion here by calling this variable up here gamma as opposed to the gamma distribution.  I apologize for using that word to mean two different things.  Since 1.6 was our value, that’s the closest to two.  Two is the closest one of these values, and that’s reassuring that we should have used the gamma after all.  It may come out different.  My experience has been that Poisson and gamma, with healthcare cost data, are the usual things that you get, that those are the most likely values.  I have to say that the only time that I’ve really come out with anything other than the log link and the gamma distributional family is with pharmaceutical costs in studies, which seem to be less skewed.  So the square root distribution and the Poisson family seem to work out better, but that just happens to be the data from those studies.

So that question about what if it’s halfway between, there is a way now, in Anirban Basu’s paper—the cites for all these papers are at the end of the slides—is you can estimate with a Stata routine the link function, the distribution, and all the parameters in a single model.  Essentially you’re estimating the theta and that gamma that you used to choose the family distribution and the parameters of your model all at once.  This has an advantage.  It has one disadvantage, that you might over-fit the data trying to do all of this in a single step like this.  But that is probably the most modern and most sophisticated way of doing it.  I’m not going to illustrate that example here, but I’ll just say that’s something that’s relatively a recent development in econometrics and is probably now the state of the art.  Are there any questions about what we’ve just gone through that we can help people with?

Moderator:  Paul, someone noted that with a lag when you said you recommend not using SAS because it can’t handle the zeros, someone sent a message that you can just make those zeros one, a very small cost.

Paul G. Barnett:  Right. And we talked about that last time.  That’s true.  The one disadvantage of that is you could make them a small positive value; you could make them a penny, a dime, or a dollar.  But the problem is the difference between a penny and a dime is the same difference, since we’re working in logs, as the difference on the other end of the scale between ten thousand dollars and a hundred thousand dollars.  So that choice of a penny or a dime could be—the small positive value that you substitute for zero could be very influential on your parameter estimates.  Unless you have very few zeros, you’re getting into some dangerous ground.  Now, if you do it with a penny, a dime, a dollar, and it doesn’t make any difference in your parameter estimates, well, then okay.  That’s reasonable.  But it could be quite sensitive to your choice of what is the small positive value that you use to take the log off, in essence.  

I’m not sure that just to accommodate the fact that SAS hasn’t programmed it right that I would do it that way.  I guess we all have the ability to use Stata if we sign up for the [VINCI] data center up in—it’s actually in Austin but run by VINCI out of Salt Lake.  Stata’s one of the products that they have on their system.  SAS is all that’s available in Austin, but both SAS and Stata are available in VINCI.  Any other questions that we have here?

Male:  Not that I see right now.

Paul G. Barnett:  Let’s move forward then.  What do we do when there are lots of zeros?  We can accommodate zeros in GLM models, but sometimes we have a situation where we’ve got a lot of zero values, where participants have enrolled in a health plan who don’t have any utilization.  And we gave an example of looking at people who use VA in fiscal ’10 and what was their cost in the prior year; there were a substantial number who didn’t incur any cost in the prior year.  That’s that left part of the distribution.  So that’s just an example of data like that.

One approach is the two-part model, sometimes called a hurdle model.  And the first part of the hurdle is was any cost incurred?  You create a variable that indicates this person incurred costs or didn’t incur costs in the data set.  The second part is a regression that’s how much cost is incurred among those who had costs.  It’s a conditional cost regression.  So then we have it expressed as the expected value of Y, which in this case is the cost, conditional on X, our explanatory variables.  The first part is the probability that Y is greater than zero; that is, the person had cost conditional on whatever your independent variables are, your case mix or your treatment group assignment, intervention, whatever.  

Part two is that expected value of Y.  That is, what are the costs conditional on this person being one of those people who used health services and their independent variables?  It’s a product of these two things.  And then when we want to predict our Y, we just take our probability of having a cost being incurred times the expected cost, given they had cost.  Now, the part one is we’re trying to predict a probability that someone had any cost.  In this case, we have an indicator variable, takes a value of one if cost is incurred and zero is no cost incurred.  So what kind of regression would we use when our dependent variable is dichotomous?  It takes a value of zero or one.  That’s a question for our class if people could put their answer in the questions seminar.  

Female:  The responses you’ve gotten in, Paul, are logistics regression and multi-variance.

Paul G. Barnett:  Well, those both could be right, but logistic regression is the key issue.  A logit is when the dependent variable is zero-one; we can’t use Ordinary Lease Squares because the dependent variable is not normally distributed.  The logistic regression is exactly right.  We could also use probit, but logistic regression estimates this log odds ratio as a linear function of our parameters, our independent variables.  So this is just one way of expressing what a logistic regression does.  If we did it in SAS, we’d use Proc Logistic.  We could keep that output, the results, into a data set and keep what the probabilities are for each person.  So we save the predictive probability.  The descending option is required because SAS will otherwise estimate the probability that the dependent variable equals zero.  I’ve never understood exactly why SAS does it this way, but that’s how you would have SAS estimate the probability that the dependent variable equals one, by using that descending option in the model statement.  In Stata, we do it this way to save our probabilities, to run our logit and save our probabilities.  I made one mistake here; there’s no equal sign in the logit.

Then the second part of the model is a conditional regression that’s conditional only to observations that have non-zero cost.  We could, in this case, either use GLM or use our Ordinary Least Squares with log cost, whatever is appropriate.  These two-part models have separate parameters for the participation; that is, did being in this treatment group or this case-mixed category cause you to incur any cost and how much cost if you did incur cost?  Each parameter means something in terms of its policy or what inferences you’re trying to make from your data.  But the disadvantage of the two-part model is it’s hard to predict a confidence interval around the predicted cost given the independent variables in the model.  So that’s much more complicated to do because you’ve got these two separate parts of the model.  That’s the disadvantage of the two-part model.  You really want to use a two-part model or a hurdle model if you want to distinguish the effect of your intervention on participation from the conditional quantity of cost.  The alternatives we’ve talked about are using OLS with untransformed cost, OLS with log cost and using that small positive value.  But we’re worried about a choice of small positive value, that assumption driving your results, and then the GLM models that we talked about in the first part of the talk.

Now, the third part is today, what if you want to make no assumptions about distribution?  None of the five assumptions that are necessary for Ordinary Least Squares or the assumptions that are needed to do a GLM?  How do you test those differences?  And so we have a non-parametric test.  The Wilcoxon rank-sum test assigns a rank to every observation, and then it compares the ranks of the groups and assigns a probability that that ordering could have happened by chance alone.  There’s also a way to do this if you’ve got more than two groups, using a Kruskall Wallis test and then using the Wilcoxon test as a follow-up test to compare pairs of groups.  So say you have three groups; the Kruskall Wallis test, you say, “Well, two of them are different.”  Then you can take each possible combination of two groups and compare them and say, “Which two are different?”  That’s analogous to analysis of variance; it tells you something’s different and then you make some post-[inaudible] comparisons.  

The non-parametric test, though, because it doesn’t make any assumptions—it compares the ranks and not the means—it ignores the influence of outliers, and so it may be too conservative.  I give the example here; say you have two interventions that have equivalent ranks.  But one of them results in having one observation that is a million dollars more costly.  That would give you the same answer as if were just one dollar more costly, so you’re really ignoring those outliers because the rank hasn’t changed for that top observation.  The Wilcoxon really is ignoring some of those influential outliers, which we really care about.  The whole question of healthcare cost is really those small numbers of people who have a very high cost.  So the Wilcoxon can be just too conservative.  And then the Wilcoxon doesn’t allow you to have case-mixed variables; we’ll only be able to compare two groups or maybe a couple of groups.  But we’re not able to control for case-mixed while we do it.  So those are the limits of the non-parametric test.  It doesn’t require you to make assumptions, but maybe it’s too conservative and doesn’t allow you to have case-mixed variables.

Finally, we want to turn to which of these methods should I use?  Which is best?  The way to do this is to look at your predictive accuracy of your model.  You can do this by estimating your regression model with half the data and test its predictive accuracy with the other half of the data.  The measures of predictive accuracy include two that I’ve listed here, the mean absolute error and the root mean square error.  The mean absolute error is you can go to each observation, and it’s just the difference between the observed and the predicted cost.  And then you take its absolute value.  You basically turn it into a positive and find the meaning of that.  If observed was predicted greater than [inaudible], it doesn’t matter.  You’re transferring them all into a difference, the mean absolute error.  And then the model that yields the smallest value is the one that has the best [inaudible].  So that is how you would choose based on mean absolute error.  The root mean square error is similar, but rather than taking absolute value you square the differences and then take the differences between the predicted and actual mean and find their mean and find their square root.  The best model here also has the smallest value, root mean square error.  There are other approaches to assessing model fit; you can look at the mean residual or the mean predicted ratio of predicted-to-observed.  The mean predicted can also be done for each decile of your observed cost.  This actually can be a really important thing to figure out is that maybe your model does really well in the middle of the range of cost, and most of them do.  But it’s at the extremes that you get into trouble, typically at the high extreme that the model doesn’t predict the high-cost observations very well.  This is sometimes a very important thing to look at when you’re trying to assess goodness of fit.  

There’s actually a variant of the Hosmer-Lemeshow test, which formally tests that question, is the residuals in each decile in the raw scale significantly different from each other, and if that F-test is big and significantly different you fail this test.  That Hosmer-Lemeshow test applied in this case can be quite useful.  There is also the Pregibon link test about testing whether linearity assumptions were violated.  So I just refer you to this paper by Manning, et al about that test of model fit.  Are there questions about which model to use?

Moderator:  A couple of questions have come in that I didn’t stop you for.  One is for the two-part model, someone asked, “Can the Xs be different in part one and part two?”

Paul G. Barnett:  Yes, I think that’s the answer.  Although I think you’d be a little bit worried about why they were different unless you had some sort of strong priors about why you included some variable in one part and not the other.  But you could see where some variable that might predict participation, that is, getting any health services, might not be a very important variable in predicting how much health service is conditional on getting some.  So there’s no constraint on that you have to have the same independent variables in both models.  I guess if I were a reviewer, I’d really want to have some sort of justification why that was done that way.

Moderator:  The second question is, “If I have a square root link function, how do I interpret the coefficients?  Do I raise them on the second power?”

Paul G. Barnett:  It doesn’t have a naturalistic explanation like the others do.  If we were dealing with Ordinary Least Squares, the parameter is just for each unit change of X, what’s the unit change in cost?  For the log function, for each unit change in X what’s the percent change in cost?  But for square root there’s nothing so neat as that.  That is probably one disadvantage of these more exotic link functions is you don’t have a naturalistic interpretation of what the parameters mean.  Now, if you want to retransform, that is fine to predicted value, yes.  You take your alpha plus X data and you square it, and that’s your predicted value exactly right.  But the parameters themselves, the betas, there’s not a real easy way to explain what they mean except that positive means higher cost.

Moderator:  Then one other thing that someone noted when you talked about the limits of the SAS procedure early on, they mentioned, “I was wondering if SAS Proc GLIMMIX would behave better with zero observations?  And how would you program this in that?”

Paul G. Barnett:  Not sure that I know what that procedure is; I do remember spending a day trying to figure this out, and I do recall looking into a bunch of different procedures to see if they would solve this problem and I did not find one.  At that point I called up SAS, and they assured me that they meant to do what they did, which is to drop the zero observations.  So if someone does find a way around this in SAS, I’d love to hear about it.  But SAS doesn’t seem to offer any solutions.

Moderator:  The final question I have out here is people are asking, “Is your Stata code available for download?”

Paul G. Barnett:  Sure, we can make that little program available to you.  We will also direct you to Will Manning’s Web site at University of Chicago, where he has some much more sophisticated Stata code than I showed you today, where he runs a lot of these different tests.  Really, anything that I understand about this I owe to his pedagogy.  

Let’s just do a little review just to say that cost is really a difficult dependent variable skewed to the right by high outliers and could be truncated on the left by zero values and the fact that it can’t be non-negative.  That makes the application of Ordinary Least Squares, the classic linear model, problematic and prone to bias, especially if there are small samples with influential outliers.  Last time we showed just graphically how one skewed value out there to the right of the distribution can have a tremendous influence on your parameter [essence]. If we log transform the cost, then we end up with a dependent variable log cost that is more normally distributed and can be estimated with Ordinary Least Squares.  So that’s an advantage.  But when we use log cost and we want to find predicted cost, we have to correct for retransformation bias.  The smearing estimator is one way to do this, but it assumes that the errors are homoscedastic.  So that predicted value is biased if the errors are actually heteroscedastic; it can be horrid if heteroscedasticity’s important.

Now, the option is to do a GLM and a log link with gamma variance as a common specification that allows for heteroscedasticity, doesn’t have the problem of retransformation bias, may not be very efficient, but it allows for zero-cost observations.  There are some alternate specifications that you can use: Poisson instead of gamma, square root instead of log link.  Those are the more common ones.  And we reviewed how you figure out if one of those alternate specifications is appropriate.  When you have a lot of zero values, maybe you want to consider a two-part model, first part being a logit or a probit to predict whether the person had any participation in the health care system, incurred any cost.  The second part is a conditional cost regression among those people who had cost.  So you’re just estimating that conditional cost regression throwing out the zero-cost values.

Then we can make inferences about cost without making any assumptions about the distribution using non-parametric tests, but they’re awfully conservative.  So we might be so conservative that we can’t detect a statistically significant effect when, if we made some reasonable assumptions, we would think there was statistical significance between the groups.  And then the non-parametrics don’t allow co-variance, so that’s another disadvantage.  Then we have ways of evaluating models using our mean absolute error, root mean square, and other tests like the Hosmer-Lemeshaw test to evaluate the goodness of fit of our model.  

I have some publications here on general linear models that I’ve referred to, some sources on the two-part models.  So hopefully you’ll have these slides, be able to look these up if you need them.  These are some examples of some worked examples that I think are real useful to understanding this.  The second one by Maria Montez-Rath and Amy Rosen and their group is based on VA data and is a very interesting one, and there are some more work examples.  Maria did a presentation for us five and a half years ago.  I checked; it’s still on the cyber seminar archive, so you can listen to it just as easily as you did today’s talk by clicking on that link or just downloading the slides.  She really goes through the details of how they use that root mean square error—I mean, absolute error to assess the goodness of your model fit.  There’s also this good book chapter by Will Manning.

Moderator:  Paul, some more things came in.  People are asking about links for the slides for the other lectures including part one.  And there are a couple of other questions here, Paul, for you.  One is, “How many zeros is a lot, leading you to use a two-part model?”

Paul G. Barnett:  Actually I think the real choice there about using a two-part model or not is, what is your goal?  Is your goal to predict what’s the effect of independent variables on cost?  Or is it, are you really interested in the parameter for participation as opposed to the parameter for how much cost conditional incurred on cost?  In other words, the two-part model’s really useful if you want to disentangle the effect of, say, treatment group assignment or the effect of certain patient characteristics on participation separate from conditional costs.  I don’t know the answer to when the GLM might break down.  If you have two-thirds of the data are zero, I’m sure that the GLM is not going to work for you very well.  

I don’t know that there’s any worked-out rule on that, but I think that would be a pretty unusual—in that situation where you have preponderance of zeros I think you definitely want to use a two-part model.  I don’t know that there are any guidelines about “Is ten percent zero costs too many to do a GLM?  Is thirty percent?”  I don’t know of any rule to do that.  If someone would send HERC an email, we’ll research that if you really want the answer and see what we can find out about that. 

Moderator:  Another question here, “How can I pass zero value for cost if I’m using SAS PSS?”  

Paul G. Barnett:  I don’t know how SPSS handles a GLM model; we don’t tend to use SPS here.  We have access to it, but I have never tried to do any of these models with it so I don’t have an answer to that.

Moderator:  Can we use the message you mentioned, mean absolute error, etc., to compare between the generalized gamma model and results with a two-part model.  If not, how can we tell which is best?

Paul G. Barnett:  Well, yes, you could.  You could do exactly that, and that may be the answer to the prior question too, which offers the better fit?  The only caveat on that is—essentially what you’re doing is predicting the costs with both models and then seeing which does a better job of fitting the data.  The complication, I would think is—yes, that sounds like a good idea.  It also sounds hard.  But yes, you could do that.

Moderator:  Related to that, someone’s asking if these methods for evaluating models in SAS, Proc GENMOD, or Stata, and I think the answer to that is probably you’ve got to program it yourself, methods of evaluating models.

Paul G. Barnett:  Will Manning has some code for Hosmer-Lemeshaw test, and it’s not too complicated really.  But that is a little—a few lines of Stata coding to be sure.  Some of these things—I think there are routines that are written to do mean absolute error and root mean square error.  I’m not even sure that some of the tests may actually generate those—I guess not.  I was thinking that maybe the GLM generated those, but it doesn’t.  So yeah, they’re fairly straightforward, like two or three lines of code to generate those.  It’s not hard.

Moderator:  Then one other thing is what is the model we use in part two of the two-part model, and how is it linked to the results of part one?

Paul G. Barnett:  The second part is just, you’re taking all of the people who have all observations with positive costs, and you’re running a regression with them.  So it goes back to just all of the things we said is you probably don’t want to do raw costs.  You probably want to do either log transform cost with Ordinary Least Squares, or you could use one of the general linear model methods in that second part.  But the point is in that second part you’ve thrown out those zero values because the first part is estimating what’s the chance of having positive cost and the second part is given that you have positive cost, how do the independent variables predict how big those costs are?  It’s just the same thing.  You could use the log cost in an Ordinary Least Squares, or you could use a GLM model if you think the assumption of homoscedasticity is not a good one.  I guess there are tests, aren’t there, [Kieren], for heteroscedasticity?

Moderator:  Yeah.

Paul G. Barnett:  But is that the White test or something like that?

Moderator:  There is a test, and there’s also a correcting of standard errors that’s been incorporated as the robust standard errors in Stata, the Huber-White estimator.

Paul G. Barnett:  Well, it’s a lot of fun.  How many folks did we have?

Female:  The largest number I saw was 123.

Paul G. Barnett:  Please feel free to send us an email if you need some follow-up, and we’ll do the best we can.  That would be email to herc@va.gov.  Thanks so much.         

(End of recording)