optimizer: Find The Best Specifications

Description Usage Arguments Examples

Description

This function searches for regression model specifications with the lowest MAPE, taking inputs of a data frame, a dependent variable, a list of potential independent variables, and a regression model.

Usage

1
2
3
4
optimizer(data, depVar, indepVar = colnames(data)[colnames(data) != depVar],
  include = NULL, model = c("OLS", "binary probit", "binary logit",
  "ordered probit", "ordered logit", "multinomial probit", "multinomial logit"),
  time.series = FALSE, timeVar = NULL)

Arguments

data

a data frame

depVar

a dependent variable

indepVar

a list of independent variables the subsets of which the dependent variable will be regressed on. Defaul is all variables in the data frame but the dependent variable.

include

a list of independent variables included in all regressions

model

regression model to estimate, including "OLS", "binary probit", "binary logit", "ordered probit", "ordered logit", "multinomial probit", "multinomial logit"

time.series

logical. This is used to decide the partition process.

timeVar

the time series variable

Examples

1

PiotrLeTrong/regressr documentation built on May 20, 2019, 1:31 p.m.