Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: RE: RE: Sorting Data


From   "Mkenda A.F" <[email protected]>
To   [email protected]
Subject   Re: st: RE: RE: Sorting Data
Date   Thu, 14 Nov 2002 13:21:08 +0300

Thank you very much, I will give it a try!
Mkenda

At 06:22 PM 11/13/02 -0000, you wrote:
>Ray, Bryan
>>
>> Just a quick comment on the analysis of these data...It
>> looks like a vote
>> can be either yes, no, or abstain. I am no expert on UN
>> voting patterns and
>> the like, but I just thought that there might be some
>> significance to the
>> abstentions that you might lose by simply looking at, for a
>> given vote,
>> votes that match the U.S.'s vote.
>>
>> Maybe you have already thought about a way to deal with this or have
>> determined that it is not an issue, but I thought it
>> worthwhile to raise.
>
>Good thought. Irrespective of whether A.F. Mkenda wants
>to follow this up, a way of implementing this may
>be of interest:
>
>Your scores may well differ, but I'll illustrate
>with
>
>label def vote 1 "N" 2 "A" 3 "Y"
>
>We initialise a counter again:
>
>gen howdiff = 0
>
>Now loop over the variables:
>
>forval i = 1 / 5 {
>	encode vote`i', gen(Nvote`i') label(vote)
>	replace howdiff = howdiff + abs(Nvote`i' - Nvote`i'[4])
>}
>
>Again, this wires the observation number
>of the US (4 in what I had after a -sort-).
>
>Nick
>[email protected]
>
>
>*
>*   For searches and help try:
>*   http://www.stata.com/support/faqs/res/findit.html
>*   http://www.stata.com/support/statalist/faq
>*   http://www.ats.ucla.edu/stat/stata/
>

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index