effect_metrics_one_cor {volker}R Documentation

Test whether the correlation is different from zero

Description

The correlation is calculated using stats::cor.test.

Usage

effect_metrics_one_cor(
  data,
  col,
  cross,
  method = "pearson",
  labels = TRUE,
  clean = TRUE,
  ...
)

Arguments

data

A tibble.

col

The column holding metric values.

cross

The column holding metric values to correlate.

method

The output metrics, TRUE or pearson = Pearson's R, spearman = Spearman's rho.

labels

If TRUE (default) extracts labels from the attributes, see codebook.

clean

Prepare data by data_clean.

...

Placeholder to allow calling the method with unused parameters from effect_metrics.

Value

A volker table containing the requested statistics.

Examples

library(volker)
data <- volker::chatgpt

effect_metrics_one_cor(data, sd_age, use_private, metric = TRUE)


[Package volker version 3.0.0 Index]