cor_assoc {MiMIR}R Documentation

cor_assoc

Description

Function to calulate the correlation between 2 matrices

Usage

cor_assoc(dat1, dat2, feat1, feat2, method = "pearson", quiet = FALSE)

Arguments

dat1

matrix 1

dat2

matrix 2

feat1

vector of strings with the names of the selected variables in dat

feat2

vector if strings with the names of the selected variables in dat2

method

indicates which methods of the correlation to use

quiet

logical to suppress the messages in the console

Value

correlations of the selected variables in the 2 martrices

See Also

plot_corply

Examples

library(stats)

#load the dataset
m <- as.matrix(synthetic_metabolic_dataset)

#Compute the pearson correlation of all the variables in the data.frame metabolic_measures
cors<-cor_assoc(m, m, MiMIR::metabolites_subsets$MET63,MiMIR::metabolites_subsets$MET63)


[Package MiMIR version 1.5 Index]