Reversing order of dummy levels so Level=1 is the base

This forum is for posts that specifically focus on Ngene.

Moderators: Andrew Collins, Michiel Bliemer, johnr

Reversing order of dummy levels so Level=1 is the base

Postby Kreg » Fri Dec 01, 2017 12:00 pm

Greetings all,

I’m working on a design for a CE with two options and a SQ (Alt=3), with each option having the same five attributes. Most of the attributes are ordinal and follow a format such as 1=Low diversity, 2=Medium diversity, 3=High diversity.

I want Level=1 to serve as the base, as I find that to be intuitive. I understand Ngene treats the "furthest to the right" level as the base, so I specify my set of dummy variable levels as 3, 2, 1. Assume Level=1 is the base, my prior for Level=2 is in the range from 0 to 0.25, and my prior for Level=3 is in the range from 0 to 0.5. In practice, this is for a pilot test with no apparent equivalents in the literature, so my priors essentially reflect a coarse expectation for coefficients: Level 3 > Level 2 > 0. I specify:

b2.dummy[(u,0,.5)|(u,0,.25)] * Div[3,2,1]

I believe this is correct syntax from what I've read, but I don't recall it being treated explicitly in the manual, and my search of "dummy base level" in this forum generated an error message. Thus, I welcome any feedback -- is this the way to have Ngene treat Level=1 as the base? I've pasted the full syntax below.

Thank you very much in advance for any feedback on this.

Kreg


design
;alts = 1*, 2*, 3
;rows = 12
;block = 3
;eff=(rppanel, d)
;rep=100
;rdraws=halton(100)
;model:
U(1)= b0[(u,0,1)] + b1.dummy[(u,0,1)] * Qual[2,1] + b2.dummy[(u,0,.5)|(u,0,.25)] * Div[3,2,1] + b3.dummy[(u,0,.5)|(u,0,.25)] * Land[3,2,1] +
b4.dummy[(u,0,.5)|(u,0,.25)] * Facil[3,2,1] + b5[u,-0.1,0] * Fee[0,2,5,10]/
U(2)= b0 + b1 * Qual + b2 * Div + b3 * Land + b4 * Facil + b5 * Fee
$
Kreg
 
Posts: 7
Joined: Tue Aug 05, 2014 3:09 am

Re: Reversing order of dummy levels so Level=1 is the base

Postby Michiel Bliemer » Sat Dec 02, 2017 10:45 am

Yes that is correct. Or you can specify it how I typically do it in ascending order by only putting the base level at the end:

b2.dummy[(u,0,.25)|(u,0,.5)] * Div[2,3,1]

It is all the same, so you can choose whichever specification you prefer.

I made some changes to your syntax. I believe you want to do Bayesian priors, not random parameters, so I changed the random parameter you specified for b5 to a Bayesian prior and I changed rppanel to mnl (it is almost impossible to optimise for rppanel, it is best to optimise for mnl and evaluate under rppanel). I also changed your alternative names as I am not sure Ngene likes it if they do not have a proper name (instead of 1,2,3). Further, I changed to gaussian draws and you may want to consider increasing the number of rows as 12 is not a lot for estimating so many parameters (especially if you want to estimate mixed logit models).

design
;alts = alt1*, alt2*, alt3
;rows = 24
;block = 6
;eff=(mnl, d)
;bdraws = gauss(3)
;model:
U(alt1)= b0[(u,0,1)] + b1.dummy[(u,0,1)] * Qual[2,1] + b2.dummy[(u,0,.5)|(u,0,.25)] * Div[3,2,1] + b3.dummy[(u,0,.5)|(u,0,.25)] * Land[3,2,1] +
b4.dummy[(u,0,.5)|(u,0,.25)] * Facil[3,2,1] + b5[(u,-0.1,0)] * Fee[0,2,5,10]/
U(alt2)= b0 + b1 * Qual + b2 * Div + b3 * Land + b4 * Facil + b5 * Fee
$
Michiel Bliemer
 
Posts: 1885
Joined: Tue Mar 31, 2009 4:13 pm

Re: Reversing order of dummy levels so Level=1 is the base

Postby Kreg » Mon Dec 04, 2017 10:15 am

Thank you so much for your feedback on this.

Kreg
Kreg
 
Posts: 7
Joined: Tue Aug 05, 2014 3:09 am

Re: Reversing order of dummy levels so Level=1 is the base

Postby Kreg » Tue Dec 05, 2017 3:52 am

Quick follow up question. I'm re-running Ngene with the revised syntax. I receive the following message.

Warning: 59049 Gauss draws were created. The search may be very slow, and if this number is very high, the results may be unpredictable. You may wish to reduce the abscissa(s), or the number of Bayesian priors.

I'm not worried about speed, as the evaluations are proceeding fairly quickly. Can you clarify what "results may be unpredictable" means? Specifically, if the large number of Gauss draws may lead to inaccurate results, should I use a different approach -- such as reducing abscissas from 3 to 2 or using an alternative to Gaussian draws?

Thanks again for any feedback on this.

Kreg

PS -- on page 112 of the Ngene 1.1.2 manual, the following wording appears: "this would yield 55 = 3,125 Gaussian draws". Should that be "5^5"?
Kreg
 
Posts: 7
Joined: Tue Aug 05, 2014 3:09 am


Return to Choice experiments - Ngene

Who is online

Users browsing this forum: No registered users and 31 guests