corr_report: Perform a simple bivaraite correlation

Description Usage Arguments Value

Description

Perform a simple bivaraite correlation

Usage

1
2
corr_report(var1, var2, data, method = "pearson",
  use = "pairwise.complete.obs")

Arguments

var1

a string indicating the 1st variable you want to correlate

var2

a string indicating the 2nd variable you want to correlate

data

a data.frame containing the variables you are correlating

method

a string, the same as the method argument that is normally passed to cor, indicates which correlation coefficient to compute. Must be "pearson" (default), "kendall", or "spearman".

use

a string, the same 'use' arguemnt normally passed to cor. Indicates what to do with missing values. Options must be "everything", "all.obs", "complete.obs", "na.or.complete", or "pairwise.complete.obs" (default)

Value

this fucntion returns a list containing the following values:

vars

variables that were correlated

eff

numeric value representing the correlation coefficient

n

sample size

report

string that provides the correlation coefficient and sample size

method

the method used to compute the correlation coefficient


ethan-young/esyr documentation built on May 15, 2019, 12:45 p.m.