search for: pearson_diff

Displaying 2 results from an estimated 2 matches for "pearson_diff".

2023 Nov 15
2
Cannot calculate confidence intervals NULL
....5,18,18.5,12,13,14,11,11,12,18,20,13,23,12,11,14,16,11) ? x2=c(5,3,4,2,1,1,1,2,3,4,5,4,3,2,1,3,4.5,4.5,5.5,6,5,4,7,8,3,4,2,5,4,3) ? y2=c(11,12,13,11,10,19,21,21,13,15,18,13,12,14,19,18.5,17.5,12.5,10,9,11,13,14,16,11,18,14,13,12,12) ? # Function to calculate the difference in Spearman coefficients pearson_diff <- function(data, indices) { ? # Sample the data ? d <- data[indices, ] ? ?# Calculate the Spearman correlation coefficients for every sample ? cor1 <- cor(x1, y1, method="spearman") ? cor2 <- cor(x2, y2, method="spearman") ? # Return the difference ? return(cor1 - c...
2023 Nov 15
1
Cannot calculate confidence intervals NULL
...,13,23,12,11,14,16,11) > > x2=c(5,3,4,2,1,1,1,2,3,4,5,4,3,2,1,3,4.5,4.5,5.5,6,5,4,7,8,3,4,2,5,4,3) > > > y2=c(11,12,13,11,10,19,21,21,13,15,18,13,12,14,19,18.5,17.5,12.5,10,9,11,13,14,16,11,18,14,13,12,12) > > # Function to calculate the difference in Spearman coefficients > pearson_diff <- function(data, indices) { > > # Sample the data > d <- data[indices, ] > > # Calculate the Spearman correlation coefficients for every sample > cor1 <- cor(x1, y1, method="spearman") > cor2 <- cor(x2, y2, method="spearman") > > #...