This is a continuation of a question I had asked you in the 'Stated preference forum' in regards to have 4 models but 1 design and you recommended the following:
If you want to create an efficient design using non-zero priors, then you can optimise a single design for 4 different models simultaneously in Ngene.
''
;eff = beef(mnl,d) + milk(mnl,d) + lamb(mnl,d) + wool(mnl,d)
;model(beef):
...
;model(milk):
...
etc.
You could specify identical models, but different priors for each product.
''
So as a first step for the pilot I used a homogeneous design with 0 priors. Using pilot data I estimated an mnl model and used bayesian priors on ngene (see code below)
- Code: Select all
?consumer main
Design
;alts(beef) = alt1, alt2, neither
;alts(milk) = alt1, alt2, neither
;alts(lamb) = alt1, alt2, neither
;alts(wool) = alt1, alt2, neither
;rows = 18
;block = 3
;eff = beef(mnl,d,mean)+milk(mnl,d,mean)+lamb(mnl,d,mean)+wool(mnl,d,mean)
;bdraws = gauss(3)
;rep=250
;con
; model(beef):
?origin #, infectionlevel#, price#, welfare
U(alt1) = b2.effects[(n,0.8,0.3)|(n,0.7,0.4)]*origin[0,1,2] + b3.effects[(n,1.8,0.4)|(n,0.8,0.5)|(n,0.2,0.5)]*infectionlevel[0,10,20,30] + b4[(n,-0.19,0.04)]*price[0,1,2] + b5.effects[(n,1.9,0.4)|(n,1.07,0.5)]*welfare[0,1,2] /
U(alt2) = b2*origin + b3 *infectionlevel + b4*price +b5*welfare /
U(neither) = b6
; model(milk):
?origin #, infectionlevel#, price#, welfare
U(alt1) = b2.effects[(n,1.2,0.3)|(n,0.9,0.5)]*origin[0,1,2] + b3.effects[(n,1.3,0.4)|(n,-0.12,0.5)|(n,0.1,0.5)]*infectionlevel[0,10,20,30] + b4[(n,-1.6,0.4)]*price[0,1,2] + b5.effects[(n,0.9,0.3)|(n,0.3,05)]*welfare[0,1,2] /
U(alt2) = b2*origin + b3 *infectionlevel + b4*price +b5*welfare /
U(neither) = b6
; model(lamb):
?origin #, infectionlevel#, price#, welfare
U(alt1) = b2.effects[(n,0.9,0.3)|(n,0.3,0.4)]*origin[0,1,2] + b3.effects[(n,1.8,0.4)|(n,0.7,0.5)|(n,0.6,0.5)]*infectionlevel[0,10,20,30] + b4[(n,-0.23,0.05)]*price[0,1,2] + b5.effects[(n,1.2,0.3)|(n,0.5,0.4)]*welfare[0,1,2] /
U(alt2) = b2*origin + b3 *infectionlevel + b4*price +b5*welfare /
U(neither) = b6
; model(wool):
?origin #, infectionlevel#, price#, welfare
U(alt1) = b2.effects[(n,0.9,0.4)|(n,0.6,0.5)]*origin[0,1,2] + b3.effects[(n,2.3,0.5)|(n,1.6,0.6)|(n,1.04,0.6)]*infectionlevel[0,10,20,30] + b4[(n,-0.22,0.04)]*price[0,1,2] + b5.effects[(n,1.4,0.4)|(n,0.9,0.5)]*welfare[0,1,2] /
U(alt2) = b2*origin + b3 *infectionlevel + b4*price +b5*welfare /
U(neither) = b6
$
I was wondering if you could see if there are any obvious issues with this please?
The iterations run very slowly. I get d-errors for each of the 4 models. The mean Bayesian mnl d-error is 2.6.
b6 which is alt3 ''I will choose neither'' option defaults to 0 prior. Should I be specifying this?
I get probabilities like 0.8,0.008,0.009 which seems extremely wrong.
please advice.
Thank you
Maria