cmc_prepareData: Orders data by respondent and prepares a data set to be used...

Description Usage Arguments Value

View source: R/cmc_prepareData.r

Description

Orders data by respondent and prepares a data set to be used in model estimation

Usage

1
cmc_prepareData(idColName, choiceColName, alternatives, availColName = NA)

Arguments

idColName

String indicating the name of the column containing respondents' ID.

choiceColName

String indicating the name of the column containing respondents' choice (level coded).

alternatives

Vector containing the codes (labels) used to register choices in the database, e.g.:c(1,2,3) or c('bus','train','plane'). If mdcev==1, then it must contain the column name of consumptions.

availColName

String indicating the name of the columns containing respondents' availability. The order must be the same than in the choice coding. If ommited, full availability is assumed.

Value

Nothing. Data is loaded as a global variable.


cmcRcode documentation built on May 2, 2019, 4:50 p.m.