Category : correlation

When I use pandas.DataFrame.corr() to create a correlation matrix, I found the correlation matrix has 38 columns and the DataFrame has 81 columns. In my mind, these two columns should be the same. So why the two columns are not equal? The code corr_matrix = train.corr(method="kendall").abs() print("original DataFrame Shape {}".format(train.shape)) print("correlation matrix shape {}".format(corr_matrix.shape)) The ..

Read more

For my current project I am using sklearn.cross_decomposition.CCA. On several wepages (e.g. https://stats.idre.ucla.edu/r/dae/canonical-correlation-analysis/ or https://www.uaq.mx/statsoft/stcanan.html) it says that canonical loadings can be computed as correlations between variables and the canonical variates. However, I could not reproduce this using scipy.stats.pearsonr? Is this just false information or am I doing something wrong? Here’s an example from sklearn.cross_decomposition ..

Read more

I’ve got an entire front-end running which takes input from a user to draw a curve and this curve now needs to be cross-verified with what the correct answer should be which I already have information about. I extracted information about the Y-coordinates for every corresponding X-coordinate in both the user input and the correct ..

Read more

I have a dataframe with an ‘EVENT’ column that has three variables called click, pageview and preview. I want to check for any correlation between clicks and previews on a link? If there is, is it significant and how large is the effect? And I want to test for potential linear and binary relationships between ..

Read more