bivar.awk: Summary statistics from two variables

Description Usage Arguments Value Examples

View source: R/bivar_awk.R

Description

Read two columns of data values (say X and Y) and computes summary statistics including N, Mean, SD, Min and Max for X and Y, as well as the correlation between X and Y and the regression of Y on X.

Usage

1

Arguments

x

A dataframe with two columns (variables).

Value

Returns an summary statistics for two variables.

Examples

1
2
3
4
5
6
# creating a random dataframe with two columns (variables)
tab <- data.frame(a = sample(1:1000, 100, replace=TRUE),
                  b = sample(1:1000, 100, replace=TRUE))

# running bivar.awk function
bivar.awk(tab)

CeTF documentation built on Nov. 25, 2020, 2 a.m.