Type: Package
Title: R Commander Plug-in for Discrete Choice Experiments
Version: 0.3-1
Date: 2025-06-14
Depends: support.CEs (≥ 0.7-0), survival
Imports: Rcmdr
Description: Adds menu items for discrete choice experiments (DCEs) to the R Commander. DCE is a question-based survey method that designs various combinations (profiles) of attribute levels using the experimental designs, asks respondents to select the most preferred profile in each choice set, and then measures preferences for the attribute levels by analyzing the responses. For details on DCEs, refer to Louviere et al. (2000) <doi:10.1017/CBO9780511753831>.
License: GPL-2 | GPL-3 [expanded from: GPL (≥ 2)]
URL: https://sites.google.com/view/r4sp/rcmdrplugin
RcmdrModels: clogit
NeedsCompilation: no
Packaged: 2025-06-14 03:16:12 UTC; r
Author: Hideo Aizaki [aut, cre]
Maintainer: Hideo Aizaki <azk-r@spa.nifty.com>
Repository: CRAN
Date/Publication: 2025-06-14 03:50:02 UTC

R Commander Plug-in for Discrete Choice Experiments

Description

This package adds menu items for discrete choice experiments (DCEs) to the R Commander. DCE is a question-based survey method that designs various combinations (profiles) of attribute levels using the experimental designs, asks respondents to select the most preferred profile in each choice set, and then measures preferences for the attribute levels by analyzing the responses. For details on DCEs, refer to Louviere et al. (2000).

Details

This package is an R Commander plug-in package for DCEs. It depends on support.CEs (Aizaki 2012), survival (Therneau 2020; Therneau and Grambsch 2000), and Rcmdr (Fox 2005, 2017; Fox and Bouchet-Valat 2020). Refer to Aizaki (2012), Aizaki et al. (2014), and ‘Non-Market Valuation with R’ <https://nmvr.skr.jp/> for a brief introduction to DCEs in R. A manual for this package is available at <https://sites.google.com/view/r4sp/rcmdrplugin>.

After successfully installing and loading RcmdrPlugin.DCE, the R Commander window will appear, and then you will find ‘DCE’ added to the top-level menus in the R Commander window.

Selecting ‘DCE’ displays menu items. When selecting a menu item, the corresponding dialog box opens. The following dialog boxes are provided by RcmdrPlugin.DCE:

Acknowledgments

This work was supported by JSPS KAKENHI Grant Number JP20K06251.

Author(s)

Hideo Aizaki

References

Aizaki H (2012) Basic Functions for Supporting an Implementation of Choice Experiments in R. Journal of Statistical Software, 50(C2): 1–24. https://www.jstatsoft.org/article/view/v050c02.

Aizaki H (2021) support.CEs: Basic Functions for Supporting an Implementation of Choice Experiments. R package version 0.5-0. https://CRAN.R-project.org/package=support.CEs.

Aizaki H, Nakatani T, Sato K (2014) Stated Preference Methods Using R. Chapman and Hall/CRC.

Fox J (2005) The R Commander: A Basic Statistics Graphical User Interface to R. Journal of Statistical Software, 14(9): 1–42. https://www.jstatsoft.org/article/view/v014i09.

Fox J (2017) Using the R Commander: A Point-and-Click Interface for R. Chapman and Hall/CRC.

Fox J, Bouchet-Valat M (2020) Rcmdr: R Commander. R package version 2.7-1. https://cran.r-project.org/package=Rcmdr.

Louviere JJ, Hensher DA, Swait JD (2000) Stated Choice Methods: Analysis and Application. Cambridge University Press.

Therneau T (2020) survival: Survival Analysis. R package version 3.2-7. https://CRAN.R-project.org/package=survival.

Therneau TM, Grambsch PM (2000) Modeling Survival Data: Extending the Cox Model. Springer.

Examples

if(interactive()) {
  library(RcmdrPlugin.DCE)
}

Create Data Set for DCE Analysis

Description

Create a data set for analysis from choice sets for DCEs and data set containing responses to DCE questions.

Details

This dialog box uses the function ce.dataset in support.CEs to create a data set for DCE analysis from the choice sets designed in the ‘Design Choice Sets for DCE’ dialog box and a data set containing responses to DCE questions. This dialog box is activated if a data frame is selected as the active data set. For details on the results of this dialog box, refer to help for the function ce.dataset.

GUI elements of this dialog box are as follows.


Design Choice Sets for DCE

Description

Design choice sets for DCEs.

Details

This dialog box uses the function rotation.design in package support.CEs to design choice sets for DCE with the rotation design method or mix-and-match method. For details on the results of this dialog box, refer to help for the function rotation.design.

GUI elements of this dialog box are as follows.


Create Interactions between Attributes/Levels and Covariates

Description

Create interactions between attribute/level variables and covariates in the data set for DCE analysis.

Details

This dialog box creates interactions between attribute/level variables and covariates in the data set for DCE analysis. This dialog box is activated if the data set created in the ‘Create Data Set for DCE Analysis’ dialog box is selected as the active data set.

GUI elements of this dialog box are as follows.


Fit Model to DCE Data

Description

Fit a model to DCE data.

Details

This dialog box fits a conditional logit model to the data set for DCE analysis using the functions clogit in survival and gofm in support.CEs. This dialog box is activated if the DCE data set created in the ‘Create Data Set for DCE Analysis’ dialog box is selected as the active data set. For details on the results of this dialog box, refer to helps for clogit and gofm.

GUI elements of this dialog box are as follows.


Calculate Marginal Willingness to Pay

Description

Calculate marginal willingness to pay (MWTP) values of nonmonetary variables from the fitted model.

Details

This dialog box uses the function mwtp in support.CEs to calculate MWTP values of nonmonetary variables from the model fitted in the ‘Fit Model to DCE Data’ dialog box. This dialog box is activated if the fitted model is selected as the active model. For details on the results of this dialog box, refer to help for the function mwtp.

GUI elements of this dialog box are as follows.


Display DCE Questions

Description

Display a series of questions for DCEs.

Details

This dialog box displays a series of DCE questions that are converted from the choice sets designed in the ‘Design Choice Sets for DCE’ dialog box. This dialog box uses the function questionnaire in support.CEs. For details on the results of this dialog box, refer to help for questionnaire.

GUI element of this dialog box is as follows.


Collect Responses to DCE Questions

Description

Collect user's responses to DCE questions.

Details

Three types of dialog boxes are provided to collect user's responses to DCE questions that are converted from the choice sets designed in the ‘Design Choice Sets for DCE’ dialog box.

The first dialog box (‘Set Options for Response Collection’) sets four options for response collections:

After confirming all the settings on the first dialog box, press the ‘OK’ button to continue.

A series of dialog boxes (‘Collect Responses to DCE Questions’) sequentially opens to collect the user's responses to DCE questions. In each dialog box, alternatives designed in the ‘Design Choice Sets for DCE’ dialog box are presented. The user is asked to select their most preferred alternative from the drop-down list box. After making the selection, the user clicks the ‘OK’ button to open a new dialog box corresponding to the next DCE question.

When all user responses to DCE questions have been collected, a dialog box (‘Save As’) opens if the ‘Save to file’ option was selected in the first dialog box. This saves the user's responses to an external file in CSV format.