# Is it OK to remove columns with low numbers in before running a chi-squared test?

I'm looking at significant differences for conversion by browser using a chi-squared test. My table looks like this:

                    Firefox     Chrome    Safari    IE      Opera Mini    UC Browser
Converted           63463       23525     42235     82352   52            12
Not converted       38980       18828     21232     39844   2             4


I know that I shouldn't use chi-squared tests for values below 5.

My question is this: Is it OK to simply ignore the last two columns, and run a chi-squared test on the remaining table?

Or does this in some way invalidate the test?

• This is a common misconception: the rule of thumb is to be concerned about the accuracy of the $\chi^2$ p-value when some of the expected counts are less than $5$. In your table all expected values exceed $5$. (There's no difficulty anyway: the huge counts guarantee the differences are "significant," but the usefulness of that result is questionable.) The question is still a good one, though, and deserves a thorough and thoughtful explanation. (When columns or rows are combined post hoc, one needs to be concerned about degrees of freedom.) – whuber Sep 23 '14 at 16:52
• I see - that's useful, thanks for the explanation. – Richard Dec 17 '14 at 12:38

It is more common to collapse columns rather than ignoring columns, you could combine the last 2 columns into a new column "Other" (you should be clear about what you did and why in any write-up) then all the numbers will be over 5. Another option is to use a permutation (or resampling) test to find your p-value/critical value instead of the chi-square table. The chisq.test function in R has an option to do this for you.
• You ought to clarify which "numbers" you are talking about, because for the example provided in the question there is no need to combine the last two columns and the appearances of $2$ and $4$ in them are irrelevant. – whuber Sep 23 '14 at 16:54