Error message - Attribute:GetLevelOrderNumber

This forum is for posts that specifically focus on Ngene.

Moderators: Andrew Collins, Michiel Bliemer, johnr

Error message - Attribute:GetLevelOrderNumber

Postby EliseS » Thu Mar 07, 2024 6:17 pm

Dear Dr. Bliemer

I am designing a partial profile choice experiment in Ngene and trying to generate an implicit partial profile design where only 5 of the 8 total attributes are shown to respondents. I created a spreadsheet following the NGene manual to generate the candidate set https://drive.google.com/file/d/1W31LqJ_dbsmZRvtRBbXnDeymc1w335aQ/view?usp=share_link.

I used the following code in NGene:

Code: Select all
design
;alts = BehandelingA*, BehandelingB*
;rows = 15
;eff = (mnl,d)
;alg = mfederov(candidates = implicit_partial_profiles_100.xlsx)
;model:
U(BehandelingA) = b1.dummy[0|0.01]               *administration[1,2,3]                      ?1=pil, 2=infuus, 3=spuit
                 + b2.dummy[0|0.01]              *frequentie[1,2,3]                          ?1=dagelijks, 2=2weken, 3=4weken
                 + b3.dummy[-0.01]               *snelheid[1,2]                              ?1=dagen/weken, 2=weken/maanden
                 + b4.dummy[-0.01]               *extra-intestinaal[1,2]                     ?1=ja, 2=neen
                 + b5.dummy[-0.01|-0.02]         *huidproblemen[1,5,20]                      ?1=minder1%, 5=5tot10%, 20=meer20%
                 + b6.dummy[-0.01]               *infecties[1,5]                             ?1=minder1%, 5=meer5%
                 + b7.dummy[-0.01]               *cardiovasculair[1,5]                       ?1=minder1%, 5=meer5%
                 + b8.dummy[-0.01]               *kanker[1,2]                                ?1=nietverhoogd, 2=verhoogd
                 /
U(BehandelingB) = b1  *administration
                 + b2 *frequentie
                 + b3 *snelheid
                 + b4 *extra-intestinaal
                 + b5 *huidproblemen
                 + b6 *infecties                             
                 + b7 *cardiovasculair
                 + b8 *kanker
$


My problem is that when I run the code, I get the following error message: Attribute:GetLevelOrderNumber https://drive.google.com/file/d/106g6UdASI3jdH3-MjE-nqcu3pU6tvPX2/view?usp=share_link. Further, I receive the following error message when closing the NGene tool after receiving the error message: https://drive.google.com/file/d/1SA-UHYIdY7SxGzQxs_YKP9rq6hegk2f1/view?usp=share_link. I looked the message up online, but did not found anyone else encountering the same problem. I do not know if you can help me and know what is wrong?

I really appreciate your insights on this matter.

Best regards,

Elise
EliseS
 
Posts: 2
Joined: Wed Mar 06, 2024 2:01 am

Re: Error message - Attribute:GetLevelOrderNumber

Postby Michiel Bliemer » Fri Mar 08, 2024 3:47 pm

The issue seems to be that there are unexpected attribute levels in your design. For example, you specify:

b6.dummy[-0.01] * infecties[1,5]

However, in your data I see infecties=0, which is not an allowable level according to the Ngene script. So you would need to specify

b6.dummy[..|-0.01] * infecties[0,1,5]

But perhaps level 0 is not a real level in your model? An mentioned in the manual, you can only use a value of 0 for numerical variables to make it drop out. To make it drop out as a categorical variable, you should simply keep infecties[1,5] but in your candidate set create overlapping levels, e.g. A.infecties=1 and B.infecties=1, or A.infecties=5 and B.infecties=5. By setting them the same level, it drops out of the model for that choice task. When you implement your choice experiment, you simply omit attributes with overlapping attribute levels (in case of an implicit partial profile design), or you show the overlapping levels (in case of an explicit partial profile design).

Michiel
Michiel Bliemer
 
Posts: 1885
Joined: Tue Mar 31, 2009 4:13 pm

Re: Error message - Attribute:GetLevelOrderNumber

Postby EliseS » Fri Mar 15, 2024 8:01 pm

Dear Dr. Bliemer

Thank you for the prompt response and the valuable insights! I changed the NGene script and the candidate set as you proposed. The error message is gone now and everything works.

Elise
EliseS
 
Posts: 2
Joined: Wed Mar 06, 2024 2:01 am


Return to Choice experiments - Ngene

Who is online

Users browsing this forum: No registered users and 16 guests

cron