| pork {support.CEs} | R Documentation |
Synthetic respondent data set: consumers' valuation of pork
Description
Data set artificially created for an example based on a labeled DCE design. This example illustrates consumers' valuation of pork.
Usage
data(pork)
Format
Data frames with 200 respondents on the following 6 variables.
IDIdentification number of respondents.
BLOCKSerial number of blocks to which each respondent had been assigned.
q1Response to choice experiment question 1.
q2Response to choice experiment question 2.
q3Response to choice experiment question 3.
q4Response to choice experiment question 4.
Author(s)
Hideo Aizaki
See Also
make.dataset, make.design.matrix, Lma.design, clogit
Examples
library(survival)
if(getRversion() >= "3.6.0") RNGkind(sample.kind = "Rounding")
d.pork <- Lma.design(
attribute.names = list(
Price = c("100", "130", "160", "190")),
nalternatives = 3,
nblocks = 4,
row.renames = FALSE,
seed = 987)
data(pork)
dm.pork <- make.design.matrix(
choice.experiment.design = d.pork,
optout = TRUE,
continuous.attributes = c("Price"),
unlabeled = FALSE)
ds.pork <- make.dataset(
respondent.dataset = pork,
choice.indicators =
c("q1", "q2", "q3", "q4"),
design.matrix = dm.pork)
fm.pork <- RES ~ ASC1 + Price1 +
ASC2 + Price2 +
ASC3 + Price3 +
strata(STR)
out.pork <- clogit(fm.pork, data = ds.pork)
out.pork
[Package support.CEs version 0.7-0 Index]