pvMatrix: Calcultes the Value Matrix

Description Usage Arguments Details Value Examples

Description

According to the parameters, it first calculates the normalized gain and loss matrices. Using prospect_value_matrix_extend it calculates the value matrix using the value function given by Tversky & Kahnemann(1992)[1].

Usage

1
2
3
pvMatrix(dataset, userid = NULL, attr = NULL, rounds = NULL,
  refps = NULL, cost_ids = NULL, alpha = 0.88, beta = 0.88,
  lambda = 2.25)

Arguments

dataset

a data.frame with the user generated data from a product configurator. See Details of decisionMatrix for more information about which data should included in this argument.

userid

an integer vector indicating for which user the output of this function should be calculated. This functions is vectorised in this argument, i.e. you may enter more userIDs simultaneously.

attr

attribute IDs, vector of integer numbers corresponding to the attributes (columns) you desire to use.

rounds

integer vector, text option or a list of integer vectors. Which steps of the configuration process should be shown? Defaults are first and last step. Text options are all, first, last. Alternatively, a vector of arbitrarily chosen rounds can be entered as well.

refps

a list of numeric vectors, one for each user. Reference Points: each point corresponds to one attribute, therefore the amount of attributes and of refps entered, should be equal. Default assumes the refps as the default values of the initial product configuration for each user. You may fully or partially enter your own reference points, check below for more info.

cost_ids

argument used to convert selected cost attributes into benefit attributes. Integer vector. Cost type attributes have the characteristic, that a lower value means the user is better off than with a higher value. E.g. price is often considered a cost type attribute. Should be equal to attr input or a subset of it.

alpha

parameter for diminishing sensitivity in the gain domain. Default value = 0.88. Usual values are in the (0,1) interval.

beta

parameter for diminishing sensitivity in the loss domain. Default value = 0.88. Usual values are in the (0,1) interval.

lambda

parameter for loss aversion. Default value = 2.25. Values for lambda should be > 1.

Details

dataset We assume the input data.frame has following columns usid = User IDs, round = integers indicating which round the user is in (0-index works best for 'round'), atid = integer column for referring the attribute ID (1 indexed), selected = numeric value of the attribute for a specific, given round, selectable = amount of options the user can chose at a given round, with the current configuration. This is a necessary parameter.

userid is a necessary parameter.

For more details on the other parameters, please refer to decisionMatrix.

Value

the value matrix

Examples

1
2
3
pvMatrix(myData, 9:10, rounds="all")
pvMatrix(data_pc, 100, weight=c(0.1,0.4,0.3,0.2))
pvMatrix(full_data, userid = 25 ,alpha = 0.95, beta = 0.78)

avilesd/productConfig documentation built on May 11, 2019, 4:08 p.m.