I have a question with applying Chi-squared tests to a given set of data. Let's say that my data is numbers of different-colored MM's in a bag.
Suppose there are 6 red, 4 blue, 8 orange, 2 green, 10 purple, and 6 brown for a total of 36, while the expected value is 6 for each.
The chi-squared test for this data, after calculating $\sum\frac{(O-E)^2}{E}$, gives 6.67.
However, if I converted the discrete numbers into percentages/decimals such that the total is 1 (e.g. blue is 0.111 and expected is 0.167), the chi-squared value is different: 0.185.
I think this has to do with the fact that when the numbers are effectively scaled down, the numerator, which reflects the square of the differences between observed and expected, decreases more than the denominator, which is merely the single power of expected. But which way of performing the chi-squared test is correct?