Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Trouble with asclogit for Choice Experiment

    Dear All

    I conducted a choice experiment concerning eco labelled seafood where individuals were given 8 choice tasks in total consisting of four options per choice card where one was a none option.

    I thus have 32 rows per respondent. Below I insert a screenshot of what my data looks like.

    When I try run the code asclogit Choice Countryoforigin HarvestMethod SustainabilityLabel Price, case(Task) alternatives(Option) vce(cluster Person) an error stating variable Option has replicate levels for one or more cases; this is not allowed. Could someone please let me know what I am doing wrong.

    Many thanks
    Click image for larger version

Name:	stata.PNG
Views:	1
Size:	24.2 KB
ID:	1500167

  • #2
    If the same tasks are completed by each of the individuals, then you cannot have "Task" as your case variable since it is repeated across individuals. You can create a unique case variable as below:

    Code:
    egen Case= group(Person Task), label
    Code:
    ..., case(Case) alternatives(Option) vce(cluster Person)

    Comment


    • #3
      Dear Andrew

      Thank you. Its not the case that the same tasks are completed by each of the individuals, because task one for individual one might not be the same as task one for individuals two. If I use the code above will the results still be valid?

      Furthermore I want to show the levels for some of the attributes e.g. sustainability label, harvest method so that I can calculate the WTP for specific levels of the attributes. Do I then need to create dummy variables for these levels and include them in the logit module.

      Comment


      • #4
        Its not the case that the same tasks are completed by each of the individuals, because task one for individual one might not be the same as task one for individuals two. If I use the code above will the results still be valid?
        In the syntax, there is no way for Stata to know that a certain observation belongs to individual 1 and another to individual 2, and so on. You get the error

        Option has replicate levels for one or more cases; this is not allowed.
        because Stata finds Task=1 and Option=1 and the other combinations more than once. The case needs to be unique, so I do not see how else you can have it apart from what I suggest. You also cluster at the individual level to account for the fact that individual choices are correlated.

        Furthermore I want to show the levels for some of the attributes e.g. sustainability label, harvest method so that I can calculate the WTP for specific levels of the attributes. Do I then need to create dummy variables for these levels and include them in the logit module
        I have no clue about calculating the WTP, but if all you need are the levels of the variables, enter them as

        Code:
        i.HarvestMethod i.SustainabilityLabel
        in the regression.
        Last edited by Andrew Musau; 26 May 2019, 14:21.

        Comment


        • #5
          Dear Andrew,

          So if I have many choice sets per individual, I need a variables that varies cross each choice set, Otherwise it will not work ?

          Maya

          Comment


          • #6
            Yes, if you want to estimate the model jointly. If you do this, make sure that you cluster at the individual level. Another option is to run regressions by case such that each individual has one case, but it depends what you are looking at.

            Comment

            Working...
            X