Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: White test for heteroskedasticity: maxvar

From   "Gauri Khanna" <>
Subject   Re: st: White test for heteroskedasticity: maxvar
Date   Wed, 16 Aug 2006 08:35:30 +0000

Dear Stas,

Thank you for your suggestion. Although I was looking for a less painful way, there is nothing like going back to the basics, So, manually seems to be a way out and it did not occur to me.




From: "Stas Kolenikov" <>
Subject: Re: st: White test for heteroskedasticity: maxvar
Date: Tue, 15 Aug 2006 12:05:41 -0500

In your case, you might want to run White's auxiliary regression
manually. Most of your interaction variables will be zeroes, as those
are interactions between (presumably orthogonal) dummies; and squares
of the dummies would be dummies themselves, so even though you have
100 or whatever variables (I can only guess how you want to report
that, but that's beyond the scope of your question), you will only
have 1000 or so nonlinear terms in your White test.

On 8/15/06, Gauri Khanna <> wrote:
Dear Statalist,

I am trying to do the following test for heteroskedasticity for my cobb
douglas production function where logoutput is my dependant variable. As you
will notice I have many dependant variables. Since the white test for
heteroskedasticity is really running an auxilliary regression using the
independant variables (we do not see this auxilliary regression, we only see
the test results), I hit the maximum number of variables possible. The
regression is run in Stata SE 8.1.

regress logoutput logcorarea loglabour logmanure logfertiliserval logtrac
logox logirrigationbefore31july logirrigationafter31july cropdum /*
*/farmerdum1-farmerdum26 farmerdum28-farmerdum77 farmerdum79-farmerdum97
farmerdum99-farmerdum104 farmerdum106

. imtest, white
no room to add more variables
An attempt was made to add a variable that would have resulted in more
than 5000 or
4999 variables (Stata reserves one variable for its own use). You have
the following

1. Drop some variables; see help drop.

2. If you are using Stata/SE, increase maxvar; see help maxvar.

QUESTION1: What are my options? I tried to run the following command

set maxvar 5000

but I still get this error.

I even reduce the number of variables in my data file to just the variables
used in the regression but still the same error message. The problem is
that since I have so many independant variables I will run into this problem
no matter what as I exceed the maximum variable permissible. So, what can I

QUESTION2. Would this work in Stata 9 i.e. is it more liberal with maximum
no. of variables that it can allow? Even so, I would still like to know the
solution to this problem.

And yes, I need all those dummies!

Thank you for your attention.


Ms. Gauri Khanna

Express yourself instantly with MSN Messenger! Download today it's FREE!

* For searches and help try:

Stas Kolenikov
*   For searches and help try:
FREE pop-up blocking with the new MSN Toolbar - get it now!

* For searches and help try:

© Copyright 1996–2021 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index