Binning data into 2 equal percentiles.

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Binning data into 2 equal percentiles.

Mark Webb-3
This is offered in the Visual binning section but I need to modify this and would appreciate some advice.
The SPSS version states -
If there are multiple identical values at a cutpoint, they will all go into the same interval; so the actual percentages may not always be exactly equal.

I want to have bins of 50% - and in situations where the [median] is shared by say 10% of the sample - the SPSS version gives a solution that is 40%:60%.

How can I allocate those records having the median randomly between the 2 bins ?

Regards--
Mark Webb

+27 21 786 4379
+27 72 199 1000
Skype - webbmark
[hidden email]
===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD
Reply | Threaded
Open this post in threaded view
|

Re: Binning data into 2 equal percentiles.

Spousta Jan
Mark,
 
add a small random noise to the variable first, and then create bins. For example:
 
compute aux = original_variable + uniform(0.000001) .
 
...and base the bins on the variable aux.
 
HTH
 
Jan


From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Mark Webb
Sent: Monday, June 29, 2009 3:36 PM
To: [hidden email]
Subject: Binning data into 2 equal percentiles.

This is offered in the Visual binning section but I need to modify this and would appreciate some advice.
The SPSS version states -
If there are multiple identical values at a cutpoint, they will all go into the same interval; so the actual percentages may not always be exactly equal.

I want to have bins of 50% - and in situations where the [median] is shared by say 10% of the sample - the SPSS version gives a solution that is 40%:60%.

How can I allocate those records having the median randomly between the 2 bins ?

Regards--
Mark Webb

+27 21 786 4379
+27 72 199 1000
Skype - webbmark
[hidden email]
===================== To manage your subscription to SPSSX-L, send a message to [hidden email] (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD  

_____________

Tato zpráva a všechny připojené soubory jsou důvěrné a určené výlučně adresátovi(-ům). Jestliže nejste oprávněným adresátem, je zakázáno jakékoliv zveřejňování, zprostředkování nebo jiné použití těchto informací. Jestliže jste tento mail dostali neoprávněně, prosím, uvědomte odesilatele a smažte zprávu i přiložené soubory. Odesilatel nezodpovídá za jakékoliv chyby nebo opomenutí způsobené tímto přenosem.

P Jste si jisti, že opravdu potřebujete vytisknout tuto zprávu a/nebo její přílohy? Myslete na přírodu.

 


This message and any attached files are confidential and intended solely for the addressee(s). Any publication, transmission or other use of the information by a person or entity other than the intended addressee is prohibited. If you receive this in error please contact the sender and delete the message as well as all attached documents. The sender does not accept liability for any errors or omissions as a result of the transmission.

 

P Are you sure that you really need a print version of this message and/or its attachments? Think about nature.

-.- --