summaryStats: Summary Statistics Function (summaryStats)

Description Usage Arguments Value Examples

View source: R/summaryStats.R

Description

This summary will calculate the following summary statistics for a given column in a dataset of interest: mean, median, max, min, standard deviation.

Usage

1
summaryStats(dataset_of_interest, col_of_interest, export_results = FALSE)

Arguments

dataset_of_interest

The dataset of interest that the user wants to analyze. This parameter was named this way so that it is very clear to the user what the argument should be.

col_of_interest

The column of interest that want to calculate summary statistics for. This parameter was named this way so that it is very clear to the user what the argument should be.

export_results

Logical argument, where the default argument is FALSE. If the user inputs TRUE, a csv containing the calculated summary statiatics is created within the main directory. This parameter was named this way so that the user can determine whether or not they want to export results to a csv.

Value

A data frame that contains the summary statistics. If the user specifies TRUE for the third argument (export_results), then the function should also create a csv file.

Examples

1
2
3

stat545ubc-2021/lorenzolindoPackage documentation built on Dec. 23, 2021, 5:25 a.m.