Spearman's Correlation with Nominal Variables
Posted: Thu Mar 31, 2022 5:48 pm
I wanted to see the correlation between the number of statements marked as true on a survey of myths [Total T] and the respondents' sex, year in college, socio-economic background, and rural/semi-urban/urban/metropolitan background.
All were ordinal variables and performed some descriptive statistics with no issues.
However, while trying to see the correlation between Total T and the other variables, jamovi didn't accept the variables, even though they were, like Total T, ordinal. I changed the entries to numbers (Female = 1, Male = 2, and so on) for each variable but jamovi still didn't accept them.
I exported the file as a .csv file, then imported it back into jamovi. This time, I was able to easily see the correlations and jamovi computed the correlation.
The output didn't disappear even when I changed the variables (except Total T) to nominal.
These variables had levels in a particular order (Metropolitan was Level 1, Urban was Level 2, Lower Class was Level 1, Middle Class was Level 2 and so on) and when I changed these to numbers I followed these levels (so Metropolitan became 10, Urban 20, Lower Class 11, Middle Class 22, and so on) before I did the exporting-importing and jamovi accepted the variables.
My question is, does that make my results invalid somehow since I changed the entries of each variable so many times? Or are my results unaffected?
Secondly, why didn't jamovi accept the variables when they were ordinal even though it showed that it accepted both continuous and ordinal variables for correlation (their icons in the bottom right corner blinked every time I tried to enter a variable like sex or year of study for correlation)?
All were ordinal variables and performed some descriptive statistics with no issues.
However, while trying to see the correlation between Total T and the other variables, jamovi didn't accept the variables, even though they were, like Total T, ordinal. I changed the entries to numbers (Female = 1, Male = 2, and so on) for each variable but jamovi still didn't accept them.
I exported the file as a .csv file, then imported it back into jamovi. This time, I was able to easily see the correlations and jamovi computed the correlation.
The output didn't disappear even when I changed the variables (except Total T) to nominal.
These variables had levels in a particular order (Metropolitan was Level 1, Urban was Level 2, Lower Class was Level 1, Middle Class was Level 2 and so on) and when I changed these to numbers I followed these levels (so Metropolitan became 10, Urban 20, Lower Class 11, Middle Class 22, and so on) before I did the exporting-importing and jamovi accepted the variables.
My question is, does that make my results invalid somehow since I changed the entries of each variable so many times? Or are my results unaffected?
Secondly, why didn't jamovi accept the variables when they were ordinal even though it showed that it accepted both continuous and ordinal variables for correlation (their icons in the bottom right corner blinked every time I tried to enter a variable like sex or year of study for correlation)?