getCorrDf | R Documentation |
Extracts correlation results in form of a data.frame
that has been constructed by melting a correlation matrix
and its corresponding p-values to a data.frame via reshape2::melt()
.
getCorrDf(object, ...)
## S4 method for signature 'Correlation'
getCorrDf(
object,
method_corr = "pearson",
across = NULL,
across_subset = NULL,
pval_threshold = 0.05,
type = "complete",
diagonal = TRUE,
distinct = FALSE,
digits = 2,
verbose = TRUE,
sep = " & ",
...
)
## S4 method for signature 'Analysis'
getCorrDf(
object,
method_corr = "pearson",
across = NULL,
across_subset = NULL,
pval_threshold = 0.05,
type = "complete",
diagonal = TRUE,
distinct = FALSE,
digits = 2,
verbose = TRUE,
sep = " & ",
...
)
## S4 method for signature 'Analysis'
getCorrMtr(
object,
method_corr = "pearson",
across = NULL,
across_subset = NULL,
type = "complete",
diagonal = TRUE,
flatten = TRUE
)
object |
Any object for whose class a method has been defined. |
across |
Character value. Specifies the discrete variable in the data.frame across which the variables of interest are to be analyzed or displayed. |
pval_threshold |
Numeric value or NULL. If numeric, denotes the maximum p-value to be considered as significant. Must no be higher than 0.05. |
type |
Character value. Denotes how the underlying correlation matrix is handled. Three options:
|
diagonal |
Logical value. Indicates if the diagonal values of the
matrices are kept ( = TRUE) or set to NA (= FALSE). Ignored if |
distinct |
Logical value. If TRUE only one observation per variable pair remains in the output data.frame. |
digits |
Numeric. Given to |
verbose |
Logical. If set to TRUE informative messages regarding the computational progress will be printed. (Warning messages will always be printed.) |
sep |
Character value. Denots the string with which the variable pairs are combined in variable var_pair of the output data.frame. |
A data.frame of class corr_df
with the following columns:
across: Factor or NULL. If factor, the group names of the grouping variable
denoted in across
.,
var1: Factor. First variable of the correlated variable pair.
var2: Factor. Second variable of the correlated variable pair.,
var_pair:Factor. Combination of var1 and var2,
corr: Numeric. The correlation vaule.,
pval: Numeric. The corresponding p-value.,
emphpval_threshold: Numeric. The denoted p-value threshold.,
signif: Logical. Indicates if the p-value of the correlated pair is below the denoted threshold.
method_corr: Character. The correlation method.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.