# correlationSelection: correlationSelection: A vector correlation function... In bertamiro/lpattern: Detection of scatterplots with L-shaped pattern

## Description

`correlationSelection` Uses the function matCorrs; given two matrices X (m,n) , Y (m,n) this function computes Pearson and Spearman correlation coefficients and their significance p-values for every pair of row vectors.

## Usage

 ```1 2``` ```correlationSelection(X, Y, type = "Spearman", adj = TRUE, pValCutoff = 0.05, rCutoff = 0, sortByCorrs = FALSE) ```

## Arguments

 `X` First matrix `Y` Second matrix. Must have the same dimensions as X. `type` specifies the correlation to choose between Spearman and Pearson. Default is Spearman. `adj` logical variable indicating if the p-value returned should be adjusted or not. Default set to TRUE, which will return an adjusted p-value. `pValCutoff` the upper limit to be used for the p-value. Default is 0.05. `rCutoff` the upper limit to be used for the correlation coefficient. Default is 0, no cut off. `sortByCorrs` logical; if TRUE, results will be ordered in ascending order by p-value. Default set to FALSE.

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21``` ```# (X <- round(matrix (rnorm(30)*10, ncol=6),1)) # (Y <- round(X + matrix (rnorm(30)*10, ncol=6),1)) # (rownames(X)=rownames(Y)=letters[1:nrow(X)]) # (m1<-matCorrs(X,Y)) # (m2<-matDistCorr(X,Y)) # (m12<- matAllCorrs (X, Y)) # correlationSelection(X, Y,pValCutoff=0.25) # correlationSelection(X, Y, pValCutoff=0.25, type="Pearson") # correlationSelection(X, Y, pValCutoff=0.25, rCutoff=0.1, type="Spearman", sortByCorrs=TRUE) # sort1(m12,1) # sort1(m12,3) # dcor(X,Y,1) # coeffRV(X,Y) # multivCorr(X,Y) #Adding an NA to X will make the preceeding fail # X[1,1] <-NA # (m1<-matCorrs(X,Y)) # (m2<-matDistCorr(X,Y)) # (m12<- matAllCorrs (X, Y)) # sort1(m12,4, DEC=FALSE) ```

bertamiro/lpattern documentation built on July 19, 2019, 12:56 p.m.