# Linear Correlation Node for ordinal Data?

Hello @all

Is it possible to use the Linear Correlation node for a correlation analysis for ordinal data?

BR Joris

Hi @Jorisr10. You have the rank correlation for that case

Hi @iperez,

i tried both and got i quite similiar results. Is it completely wrong to use the linear correlation node for such a case or ist the other only the better solution?

BR Joris

Also is it a problem, that one rank ist from 0-3 while the other is from 0-2?

Br Joris

Hi! The Linear correlation node calculates the correlation of numeric variables calculating Pearson 's product-moment coefficient and for nominal variables it does a Pearson’s chi square test on the contingency table, you can check the details on the node’s descrption window. The Rank correlation node calculates Spearman’s rho as well as other measures as Kendalls A and B tau and Goodman and Kruskal’s gamma. So I think that no, it is not completely wrong to use the linear correlation node, just decide how you want to measure the correlation

1 Like

Can you develop a little bit more your question?

Hi @iperez,

ah okay i understand.

In my case, I have a data set that contains various characteristics. These characteristics are evaluated by means of ranks. For example, feature 1 has a score from 0 to 2 and feature 2 has a score from 0-3.

I would like to find out if there is a correlation between these two characteristics.This means that I would like to find out that if feature 1 has a high score then also feature 2 has a high score or vice versa.

As far as I understand it so far, I can test a general dependency with the rank correlation and whether the dependency is linear with the linear correlation analysis.

Is that correct?

BR Joris

Hi @Jorisr10
You are right:
Pearson correlation (what you call linear correlation) measures the degree of proportionality betwen two variables, that’s why you can only apply it to continuos (and normally distributed) data. Spearman correlation measures how well the relationship between two variables can be described using a monotonic function. In other words if they both consistently increase or decrease but not necessarily at a constant rate. You can use Spearman’s correlation with variables that are at least ordinal.
having different scales of measurament on your ordinal variables does not afeect the result. In fact you are find(ing) out that if feature 1 has a high score then also feature 2 has a high score or vice versa.

2 Likes

Thank you very much!!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.