4
$\begingroup$

One of my variables to be compared in a t-test is normally distributed, while the other is non-normally distributed. What test should I use? I thought I should do a reflect log10 transformation on the normally distributed data, but this does not work in the t-test because the mean values are much higher and it is now saying there is a statistically significant difference between the two groups when I know for a fact there is not (its for a college project we already have the results just have to prove them).

What am I doing wrong?

$\endgroup$
  • 6
    $\begingroup$ If you truly believe one group has a normal distribution and one does not, then you have already asserted there is a "difference between the two groups." $\endgroup$ – whuber Nov 24 '14 at 15:53
  • $\begingroup$ well theres 270 in each group?so its givin me a skew value greater than twice the standard error skew bt on the histograms theyre bell shaped and look ok $\endgroup$ – Zoe Campbell Nov 24 '14 at 16:07
  • 1
    $\begingroup$ Don't use the standard error of the skew. It doesn't tell you what you want to know. $\endgroup$ – Jeremy Miles Nov 24 '14 at 17:52
  • $\begingroup$ what should i use then? $\endgroup$ – Zoe Campbell Nov 24 '14 at 18:32
  • 4
    $\begingroup$ Showing us your data would help get better advice. Applying a t test is in effect postulating that the most important difference between two distributions is an additive shift. Perhaps there is something more interesting and complicated going on which would be instructive. If data are paired, look at a scatter plot. If data are unpaired, look at a quantile-quantile plot. Wanting to push complicated data into a two-sample test is some times like trying on a shoe that is too small, not a good idea and it won't work. $\endgroup$ – Nick Cox Nov 24 '14 at 20:29
6
$\begingroup$

The reason you want your data to be normal for a $t$-test is to ensure the sampling distributions of the means will be normal. However, due to the central limit theorem, the sampling distribution of the means will often become normal with enough data even if the original data are not normal. I gather you have a lot of data and the histograms look OK even if the test of the skewness is significant. You are probably OK to use the $t$-test straight away.

If you do choose to use a data transformation before running your test, you should apply the same transformation to both groups. If there isn't a transformation that will sufficiently normalize both groups, you should use a test that does not require normality, such as the Mann-Whitney $U$-test.

For some related information, it may help you to read this excellent CV thread: Is normality testing 'essentially useless'?

$\endgroup$
  • 3
    $\begingroup$ Perhaps it's worth pointing that the Welch t-test may be preferable if the distributions look different, since it can make allowance for the groups having different variances. That is not a problem that large sample sizes and the CLT can be invoked to wash away. Several answers to this question prefer the Welch t-test as a default choice. $\endgroup$ – Silverfish Nov 24 '14 at 23:47
1
$\begingroup$

The test you use should depend on the question you are trying to answer as much as test assumptions.

The t-test addresses the question of whether the means of two variables are equal. It is often used because the issue of the equality of means is very interpretable in terms of an empirical question e.g. if the mean SAT scores of a group of students who took a prep course is greater than mean SAT scores of a control group, then that can be interpreted in terms of the efficacy of the prep course. However, another question you could have is whether the two variables follow exactly the same distribution, which is not theoretically the same question (e.g. two variables could have the same mean, but different variances).

If you are interested in whether the means of your two variables are equal, you should not transform one of them using the log-transform. Then your t-test asks whether the mean of Var 1 is equal to the mean of log(Var 2), and unless you are interested in and able interpret what log(Var 2) represents, you're probably not interested in what that t-test will tell you.

As has been noted, non-normality of your data is not necessarily a problem for the t-test. What is important is whether the sample mean is non-normal, not whether the data itself is non-normal. If your data is normal, the sample mean will automatically be normal as well. However, even if your data is non-normal, the central limit theorem (CLT) implies that the sample mean will be (approximately) normal so long as the sample size is sufficiently large. It is because of this that the t-test is often described as robust.

Thus the only question you have to ask in applying your t-test is whether the sample size is sufficiently large that the sample mean of your non-normally distributed variable is approximately normal. This depends greatly on how much "non-normality" your data exhibits. There are no absolute and objective rules giving a specific sample size that guarantees approximate normality of the sample mean. There are ways you could possibly examine the normality of the sample mean directly (e.g. parametric bootstrap, if you can guess the non-normal distribution of your second variable). But if your sample size is in the hundreds and it's only an issue of skew, you're probably fine (although not definitely).

If you want to be conservative (both statistically and practically) you can use a nonparametric test. Others have brought up some of them, another one you could use is a randomization test. However, make sure to keep in mind what exactly these tests answer. They are not always the same as what the t-test answers. A randomization test would answer the question of whether the variables come from the same distribution, which is a stronger question than whether the means are the same.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.