Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down at the end of May, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: calculate probability for clogit


From   Steve Samuels <sjsamuels@gmail.com>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: calculate probability for clogit
Date   Fri, 23 Apr 2010 08:10:17 -0400

I should never post to Statalist in the middle of the night.  I
apologize for the brevity of the last message.

-asclogit- worked for me in Stata 11 with two outcomes using the
choice data set.

********************
webuse choice, clear
drop if car==3
asclogit choice , casevars(sex) case(id) alternatives(car)
tab car, gen(car)
gen car2_sex =car2*sex   //add interaction of person-level variable
with alternative
clogit  choice car  dealer car2_sex , group(id)   //sex enters only in
interaction
*********************
However I don't understand the pairwise design well-enough to be sure
of what you should do.  One  guess is that the case or group variable
should not be ID but "pair" and that to get proper standard errors you
should bootstrap the command with ID as a cluster variable for the
bootstrap.  However, I think you need to consult somebody who knows
more about these analyses than I do.  If you come back a correct
analysis in SAS, for example, we can probably help  translate it into
Stata.

Steve

On Fri, Apr 23, 2010 at 12:54 AM, Steve Samuels <sjsamuels@gmail.com> wrote:
> Sorry, you are on your own.  -asclogit- worked for me with two
> alternatives in Version 11 examples with the web "choice" data set.,
> but perhaps there's something special about your data, or you did not
> have the proper format (2 records per person and option).   You can
> get person-level variables into -clogit- by adding their interactions
> with your alternative variable.    However you cannot use the -clogit-
> data format for -asclogit-.  As I said this is not my area, so read
> the manual entries.
>
> Good luck.
> Steve
>
> On Thu, Apr 22, 2010 at 9:34 PM, Patty_FARE_Guelph Apichaya
> <pattria_ft@hotmail.com> wrote:
>> Hi,
>>
>>   I try to use -asclogit- but it has to have more than 2 alternatives in 1 choice set, so I cannot use this command in my analysis.
>>  For the choice design, I use SAS software to design the pair of alternative and combination of factors in order to balance and give the optimal sets. I use clogit to analyze my choices and I want to know how I calculate probability the people choose each alternative in choice set.
>>
>> if I want to calculate personal factors, should I use -xtlogit- or which command it is appropriate?
>>
>> Thanks
>>
>> Apichaya Lilavanichakul
>> MSc. Candidate
>> Department of Food Agricultural and Resource Economics
>> Ontario Agricultural College
>> University of Guelph
>> Guelph, ON
>>
>>
>>
>>> Date: Tue, 20 Apr 2010 16:12:44 -0400
>>> Subject: Re: st: calculate probability for clogit
>>> From: sjsamuels@gmail.com
>>> To: statalist@hsphsun2.harvard.edu
>>>
>>> I know almost nothing about discrete choice experiments, so please
>>> read the following comments with that in mind.
>>>
>>> 1. -asclogit-  might be a better choice than -clogit-, as it will more
>>> easily include  person-level variables like gender, income, and sex.
>>>
>>> 2. Your setup does not identify the individual in any way. The
>>> examples for -asclogit- and -clogit-  all use the individual as the
>>> case or group variable. As "set" has only four levels, perhaps you can
>>> include it as a person-level variable.
>>>
>>> 3. The examples in -asclogit- consider  alternatives based on one
>>> attribute (factor).  You have three factors  and these generate 12 (=
>>> 3 x 2 x 2)  possible options, with 66  possible pairwise comparisons.
>>> You selected 32 of these,  divided into four sets.  I'm curious--is
>>> there  a reference for this experimental design?  Is the choice of
>>> comparisons and construction of the sets  optimal or balanced in some
>>> sense?
>>>
>>> 4. For predicted probabilities, use  the  -pr- option in -asclogit- .
>>>
>>> Steve
>>>
>>> On Tue, Apr 20, 2010 at 9:39 AM, Patty_FARE_Guelph Apichaya
>>> <pattria_ft@hotmail.com> wrote:
>>>> Hi all,
>>>>
>>>>       I use STATA to analyze discrete choihce experiment. My choice design has 32 choice sets with each 2 options (A and B). Each option include 3 factors: price (13,15,17), brand (AA,BB), labeling (animal,plant). The choice set will look like this.
>>>>                  Option A                           OptionB
>>>>     price                    13                                       15
>>>>     brand                   AA                                        BB
>>>>    labeling          animal                               plant
>>>>
>>>>            From 32 choice sets is divide into 4 block with each 8 choice sets. Each individual (100 individuals) get 1 block (8 choice sets) and ask to choose between option A or B.
>>>>
>>>>     choice = 1 chosen option, 0 not chosen option
>>>>     set = same for two alternatives for each set i.e. there are 32 choice sets, it is repeated number from 1 to 32 and start it
>>>>           again for the next 32 choice sets.
>>>>
>>>> This is the code; clogit choice price brand labeling, group(set)
>>>>
>>>> I also want to include individual characteristics; gender, income, age. how I can do it?
>>>>
>>>> How I can calculate the probability from people choosing choice?
>>>>
>>>> Any suggestion would be great.
>>>> Pat
>>>>
>>>>
>>>> _________________________________________________________________
>>>> Hotmail has tools for the New Busy. Search, chat and e-mail from your inbox.
>>>> http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_1
>>>> *
>>>> *   For searches and help try:
>>>> *   http://www.stata.com/help.cgi?search
>>>> *   http://www.stata.com/support/statalist/faq
>>>> *   http://www.ats.ucla.edu/stat/stata/
>>>>
>>>
>>>
>>>
>>> --
>>> Steven Samuels
>>> sjsamuels@gmail.com
>>> 18 Cantine's Island
>>> Saugerties NY 12477
>>> USA
>>> Voice: 845-246-0774
>>> Fax:    206-202-4783
>>>
>>> *
>>> *   For searches and help try:
>>> *   http://www.stata.com/help.cgi?search
>>> *   http://www.stata.com/support/statalist/faq
>>> *   http://www.ats.ucla.edu/stat/stata/
>>
>> _________________________________________________________________
>> The New Busy think 9 to 5 is a cute idea. Combine multiple calendars with Hotmail.
>> http://www.windowslive.com/campaign/thenewbusy?tile=multicalendar&ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_5
>> *
>> *   For searches and help try:
>> *   http://www.stata.com/help.cgi?search
>> *   http://www.stata.com/support/statalist/faq
>> *   http://www.ats.ucla.edu/stat/stata/
>>
>
>
>
> --
> Steven Samuels
> sjsamuels@gmail.com
> 18 Cantine's Island
> Saugerties NY 12477
> USA
> Voice: 845-246-0774
> Fax:    206-202-4783
>



-- 
Steven Samuels
sjsamuels@gmail.com
18 Cantine's Island
Saugerties NY 12477
USA
Voice: 845-246-0774
Fax:    206-202-4783

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index