# What test to see if variances are different when data are non-normal

What would be a good test to check if two sample variances are significantly different when data are non normal (leptokurtic, slight negative skew) and heteroskedastic?

The samples are of equal size, 500.

My impression are that most tests assume normality and homoskedasticity.

Edit: I see that my original post was a bit unclear.

I have two samples, where each sample is created by giving different weights to 10 random variables (e.g. one sample has equal weighting of the random variables, 10%, and the other sample have different weights, say 5% for 9 of the variables and 55% for the 10th). All these 10 random variables exhibit heteroskedasticity, and are non normal. The exact weighting of each random variable changes in both samples under a testing period of 500 observations.

I want to test whether or not the sample variance of these two samples are significantly different or not, is there a way to do this?

Could I in some way use Levene's test (or Brown–Forsythe)?

• This doesn't make sense. "Heteroskedastic" means that the variances are different. Can you clarify what you have in mind here? Aug 22, 2016 at 21:23
• Im sorry, I have tried to explain better in my edit Aug 22, 2016 at 21:37
• The results of those different sets of weights -- the outcomes you create -- will be dependent since they're based on the same inputs. You need to worry about that aspect of the problem. What are these left-skew variables you started with measuring? Aug 23, 2016 at 0:43
• The left skew variables are log financial returns, so each of the 10 variables are highly correlated themselves. Can you elaborate on how I need to worry about the two samples are dependent? Aug 23, 2016 at 2:14

May I suggest Conover? Conover two-sample squared ranks test for equality of variance is a non-parametric procedure and not affected by non-normality like Levene's test. Conover squared ranks is implemented in Mathematica and available for MatLab.

• Hi, I am using R. I assume this is the test you speak of, correct? cran.r-project.org/web/packages/conover.test/conover.test.pdf I dont understand all this manual says, but I get the impression that it looks at the stochastic dominance, and not solely differences in dispersion, is that correct? In the context I am using it for mean or median in itself is uninteresting, I care only about the variance. Aug 23, 2016 at 3:40
• No, the Conover-Iman test for difference of location is not the Conover test for difference of variance. The former is a rank test and the one you want is the rank squared test. Sorry for that. My bad, put the wrong link in. Conover was (is?) prolific. Now corrected above with links to the 1983 variance methods paper, and implementation in Mathematica.
– Carl
Aug 23, 2016 at 13:11
• NIST uses R. Maybe you can find a link to software on the NIST site NIST squared ranks
– Carl
Aug 23, 2016 at 13:42
• From the NIST site I see that the test assumes that the k samples are mutually independent. As they are created as dynamic weighted averages of the same 10 variables, I guess this assumption cant hold? Aug 23, 2016 at 15:15
• Yes, the k-sample test assumes that. I was suggesting use of the independent two-sample test, but perhaps you want the "THE ONE-SAMPLE OR MATCHED PAIRS PROBLEM" heading in The American Statistician, Volume 35, Issue 3 (Aug., 1981), 124-129.
– Carl
Aug 23, 2016 at 16:52

I gather you have 10 random variables that are non-normal and have differing variances. From these, you want to form two different weighted linear composite variables by combining the original 10 with different weights. From there, you want to determine if the two different weighted combinations have the same variance. (Correct me if any of that is wrong.)

The answer is straightforward: the two resulting variables cannot have the same variance. For simplicity, let the original variables be independent and consider combining only the first two using $[.3\ \ .3]$ and $[.55\ \ .05]$ as the weights. Then we can consult the formula for the variance of the weighted sum of two variables:
$${\rm Var}(aX + bY) = a^2{\rm Var}(X) + b^2{\rm Var}(Y)$$ Because you are working with the same variables, ${\rm Var}(X)$ and ${\rm Var}(Y)$ will be the same for both combinations (whatever their individual values are). So when $a_i\ne a_j$ or $b_i\ne b_j$ (e.g., $.3\ne .55$), then they cannot be the same. Thus, there is no reason to test them.

Of course, if you wanted to anyway, you could use the Brown-Forsythe test. Whether it will be significant will only depend on how much data you have.

• "I gather you have 10 random variables that are non-normal and have differing variances. From these, you want to form two different weighted linear composite variables by combining the original 10 with different weights. From there, you want to determine if the two different weighted combinations have the same variance. (Correct me if any of that is wrong.)" Almost correct. The exact weights are changing every 5th time step. When the variances are heteroskedastic, can it still be calculated the way your post suggests then? (all the weights are known). Aug 23, 2016 at 2:12
• Yes, @OlveHeitmann, the formula for the variance of a weighted sum of variables is the same. Aug 23, 2016 at 12:35