feature_matrix: Creates correlation heatmap between PCA basis vectors and...

Description Usage Arguments Value Examples

View source: R/feature_matrix.R

Description

Creates a colour-coded correlation matrix between the PCA basis vectors (determined using cum_var) and the matrix of features (determined manually after using amplitude_plots). Color-coding is done for only those correlations that achieve statistical significance after adjusting for multiple comparisons.

Usage

1
feature_matrix(corr.scores.pval, corr.scores.rval, thresh)

Arguments

corr.scores.pval

A matrix containing the p-values for each correlation coefficient after being adjusted for multiple comparisons; columns reflect plasticity features while rows reflect PCA basis vectors.

corr.scores.rval

A matrix containing the correlation coefficients between each feature and PCA basis vector; columns reflect plasticity features while rows reflect PCA basis vectors.

thresh

A threshold which each correlation coefficient’s p-value must be below to meet significance and retain their color-code (valid entries range from 0 – 1).

Value

A colour-coded correlation matrix displaying the correlations between features (X-axis) and PCA basis vectors (Y-axis). The cells in the matrix are only color-coded and labelled with the coprresponding Pearson's R correlation coefficient when statistically significant. Red tiles reflect significant negative correlations while green tiles reflect significant positive correlations. Grey tiles are not statistically significant.

Examples

1
2
3
4
5
feature_matrix(
     corr.scores.pval = corr.scores.bfpval,
     corr.scores.rval = corr.scores.rval,
     thresh = 0.05
      )

visualneurosciencelab/PlasticityPhenotypes documentation built on Sept. 7, 2020, 2:18 p.m.