Description Usage Arguments Details Value Examples
Run linear regressions on a cumulative hotel booking matrix
1 2 3 |
data1 |
a data.frame with the variables target (contains bookings on arrival date), a undefined number of lags (contains bookings at the days before arrival) and undefined number of control variables. |
lag |
number of lag regressed on |
year1 |
The year regressed on |
year2 |
Year that is used for the comparison for the same date years before |
oneyear |
If |
wdayyes |
If |
monthyes |
If |
bayernholiday |
If |
publicholiday |
If |
italholiday |
If |
season |
If |
season2 |
If |
clear |
If |
... |
arguments to be used to form the default |
runRegressions
run linear regressions on a cumulative hotel booking matrix
An object of class "lm.fit"
.
1 2 3 4 5 6 7 8 | ##create data
cBM2016 <- data.frame(a <- rnorm(n=30,mean=15), b <- rnorm(n=30,mean=10), b <- rnorm(n=30,mean=10))
colnames(cBM2016) <- c("target", "lag5", "lagp5")
## use function with sample cBM2016
runRegressions(data1=cBM2016, lag=5, year1=2016, year2=2015,
oneyear=FALSE, wdayyes=FALSE, monthyes=FALSE, bayernholiday=FALSE, publicholiday=FALSE,
italholiday=FALSE, season=FALSE, season2=FALSE, clear=FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.