MwStatistics: MwStatistics

MwStatisticsR Documentation

MwStatistics

Description

This function allows you to calculate a variety of statistics in a time series using a moving window.

Usage

MwStatistics(dat = NULL, TimeVarCol = 1, ColA = 2, ColB = 3,
win = NULL, stat = NULL, overlap = 0, genplot = TRUE, genDataFrame = FALSE)

Arguments

dat

Name of dataset.

TimeVarCol

Column number of time variable (EG: Depth or Time)

ColA

Column number of first variable

ColB

Column number of second variable

win

Window Size

stat

Calculated Statistic, Requires Quotes

overlap

Overlap between windows

genplot

If you want a plot to be generated

genDataFrame

If you want a dataframe to be generated

Value

Plot and/or Dataframe

Author(s)

William Kopans - wkopans123@gmail.com

Examples

MwStatistics(dat = data.frame(replicate(10,sample(0:10,1000,rep=TRUE))),
TimeVarCol = 1, ColA = 2, ColB = 3, win = 2, stat = "Correlation",
genplot = TRUE, genDataFrame = FALSE, overlap = 0.5)

WilliamKopans/MwStat documentation built on April 20, 2023, 10:28 p.m.