Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Sorry for my poor explanation. We have two group, say the group A and the group B. We would like to compare that the statistical difference (p-value) between these groups in term of the following age distribution at first. 1. less than 20, 2. 21-30 years, 3. 31-40 years, 4. 41-50 years, 5. more than 50 years. We found a significant difference among the age distribution in the group A and B using Chi-square test. We then tried to find p-values of each category by creating dammy variables in chi-square test. Is this acceptable way to find p-values of each category) using dammy variables?
Thank you for your message. I initially use cross-table to find out statisitical difference of the age distribution between the group A and the group B. I found out a significant difference between the groups. I then tried to find out the diffirence in each p-value using dammy variables (0 and 1) in age distributions with chi-square test. My question here is whether chi-square test can be used to find out the statistical difference in each categorical variable under these situation.