Hi,
I'm currently analysing experimental data that I collected on Qualtrics. I'm using Stata v18 on Mac. I want to run a chi square test to compare scores in condition 1 and condition 2, but the way the data is exported from Qualtrics means that I have missing values in both conditions (I have a between subject design: a missing value in condition 1 means that that participants was allocated to another condition). I've tried this command: tab cond1 cond2, missing chi2 so that Stata treats missing values as other values (otherwise I get an error message that there are missing values). I cannot replace the missing values with other values such as the mean.
I'm a bit confused by the output:
tab c1_sc3_qa c2_sc3_qa, missing chi2
Would you | Would you be upset?
be upset? | 0 1 . | Total
-----------+---------------------------------+----------
0 | 0 0 40 | 40
1 | 0 0 7 | 7
. | 29 21 1 | 51
-----------+---------------------------------+----------
Total | 29 21 48 | 98
Pearson chi2(4) = 94.0768 Pr = 0.000
Am I right in thinking that Stata cannot include the missing values in the chi square test formula, i.e. this is the correct result? Alternatively, are there other options to do run chi square tests, and / or to deal with the missing values?
Thanks in advance!
I'm currently analysing experimental data that I collected on Qualtrics. I'm using Stata v18 on Mac. I want to run a chi square test to compare scores in condition 1 and condition 2, but the way the data is exported from Qualtrics means that I have missing values in both conditions (I have a between subject design: a missing value in condition 1 means that that participants was allocated to another condition). I've tried this command: tab cond1 cond2, missing chi2 so that Stata treats missing values as other values (otherwise I get an error message that there are missing values). I cannot replace the missing values with other values such as the mean.
I'm a bit confused by the output:
tab c1_sc3_qa c2_sc3_qa, missing chi2
Would you | Would you be upset?
be upset? | 0 1 . | Total
-----------+---------------------------------+----------
0 | 0 0 40 | 40
1 | 0 0 7 | 7
. | 29 21 1 | 51
-----------+---------------------------------+----------
Total | 29 21 48 | 98
Pearson chi2(4) = 94.0768 Pr = 0.000
Am I right in thinking that Stata cannot include the missing values in the chi square test formula, i.e. this is the correct result? Alternatively, are there other options to do run chi square tests, and / or to deal with the missing values?
Thanks in advance!
Comment