conjanal: Conjoint analysis

Description Usage Arguments Details Value Author(s) Examples

View source: R/conjanal.R

Description

Metric and monotonic conjoint analysis for categorical factors

Usage

1
conjanal(resp, profile, monotone = F, tor = 1e-10, maxit = 50)

Arguments

resp

Response matrix where rows are profiles and columnes are responses from respondents. Small value for less preferable and large value for more preferable.

profile

Profile matrix where rows are profiles and columens are factors.

monotone

TRUE for Kruskal monotonic transformation. FALSE for metric scale.

tor

Tolerane for monotonic transformation.

maxit

Maximum number of itneractions for monotonic transformation.

Details

Metric conjoint analysis:
Linear regression model

Monotonic conjoint analysis:
Kruskal monotonic transformation is applied to each response column by opscale(level=2,...) in optiscale package. Linear regression is applied to the transformed responses.

Value

A conjanal object

lm

lm object. Results of the linear regression models

part

part worth for each level of each factor of each respondent

imp

Relative importance of each factor for each respondent

Author(s)

Chi-wai Kwan

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
library(conjanal)
contrasts(mydata$f1)
contrasts(mydata$f2)
contrasts(mydata$f3)

#define response matrix
resp<-as.matrix(mydata[,4:5])

#define profiles
profile<-mydata[,1:3]

fit.conj<-conjanal(resp=resp,profile=profile,monotone = TRUE)
summary(fit.conj$lm)

#part-worth
fit.conj$part

#relative importance
fit.conj$imp

#predicted utilities
cbind(profile,pred=predict(fit.conj$lm,newdata=profile))

#estimation of market shares
maxconj(fit.conj,csimp)
btlconj(fit.conj,csimp)
logitconj(fit.conj,csimp)

cwkwanstat/conjanal documentation built on Oct. 23, 2021, 8:21 p.m.