Differentiating Parameter Priors in Dummy Coded Variables

This forum is for posts that specifically focus on the Windows desktop version of Ngene (i.e. all version 1.x releases).

Moderators: Andrew Collins, Michiel Bliemer, johnr

Post Reply
bbryseck
Posts: 6
Joined: Mon Sep 21, 2020 11:44 pm

Differentiating Parameter Priors in Dummy Coded Variables

Post by bbryseck »

I'm just starting out with NGene, so please forgive me if this has been asked, but is it possible to specify different priors for a dummy variable, or for effects coding?

For context:
I would like to understand which information types transit users most need to plan a journey. For simplicity sake, let's say that these information types (attributes) are fare, departure and arrival information. Fare information has two levels: No information given or exact fare information is given. Departure and arrival information have three levels: no information given, scheduled information is given, or live information is given.
No information given on an attribute would have less utility than at least some information given. So theoretically, 'no information given' would be negatively received and therefore have a negative prior while 'scheduled' and 'live' information would have positive priors. So in order of utility (least to greatest): No information < Scheduled information <= Live information

Translating this into NGene, would this then become the following (where in the dummy coding 0 indicates the level 'no information', 1 indicates 'live' info in the case of arrival and departure, or the most information in the case of fare, and 2 indicates 'scheduled' in the case of arrival and departure)?

Design
;alts = alt1*, alt2*, alt3*
;rows = 12
;eff = (mnl, d)
; model:
U(alt1) =
+ b2.dummy[-0.001] * fare[0,1]
+ b3.dummy[-0.001|0.001] * departure[0,1,2]
+ b4.dummy[-0.001|0.001] * arrival[0,1,2]
/
U(alt2) = b2.dummy*fare + b3.dummy*departure + b4.dummy*arrival /
U(alt3) = b2.dummy*fare + b3.dummy*departure + b4.dummy*arrival
$


Is it at all possible to specify a third parameter prior in a dummy coded variable with three attributes like above?

So in essence, the relationship is a bit like that of figure 7.11 in the Ngene User Manual p.112.
Michiel Bliemer
Posts: 2057
Joined: Tue Mar 31, 2009 4:13 pm

Re: Differentiating Parameter Priors in Dummy Coded Variable

Post by Michiel Bliemer »

Dummy and effects coding in Ngene works as follows:

... + coefficient.dummy[value_1|value_2|...|value_N] * attribute[1,2,3,...,N,0] + ...

where the last level (in this case, 0) is the base level, value_1 is the value attacted to level 1 relative to the base level, value_2 is the value attached to level 2 relative to the base level, etc.

So I believe that your syntax is correct, in your case level 2 is the base level.

Michiel
bbryseck
Posts: 6
Joined: Mon Sep 21, 2020 11:44 pm

Re: Differentiating Parameter Priors in Dummy Coded Variable

Post by bbryseck »

Many many thanks!
Post Reply