FilterHolidays: FilterHolidays

View source: R/FilterHolidays.R

FilterHolidaysR Documentation

FilterHolidays

Description

Filters Holidays out of daily data

Usage

FilterHolidays(Time, Datavector=NULL,HolidaysTime = TSAT::GermanHolidays$Time,

PlotIt=FALSE)

Arguments

Time

[1:n] vector of time, as.Date or POSIXct objects are accepted

Datavector

Optional, [1:n] vector of values or a Key in case of a data frame. Default is NULL

HolidaysTime

[1:m] vector of time of holidays, as.Date or POSIXct objects are accepted. Default are german holidays, see GermanHolidays

PlotIt

Optional, TRUE: Evaluates output of function versus input by plots, works only if Datavector given. Default is FALSE

Details

deletes holidays out of input

Value

List with

FilteredTime

[1:m] vector with time objects of the m=n-k dates, which are not holidays

FilteredData

[1:m] vector with data corresponding to the m=n-k dates, which are not holidays

HolidaysTimes

[1:k] vector with time objects of the k holidays

HolidaysData

[1:k] vector with data corresponding to the k holidays

where k,m<=n and n=m+k

Author(s)

Michael Thrun


Mthrun/TSAT documentation built on Feb. 5, 2024, 11:15 p.m.