|
Hi all,
I want to use Chisquare Test to test if the proportions are equal. Four sample proportions drawn from independent populations were already computed (e.g., p1=.29, p2=34, p3=.20 & p4=.23). Sample sizes were available. Can we do it in SPSS. What is the syntax? Your help is highly solicited. Thanks. Eins --------------------------------- Importing contacts has never been easier. Bring your friends over to Yahoo! Mail today! ===================== 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 |
|
Eins,
I think you should look at the chisquare option under the npar command. Read up on it in the syntax reference. Gene Maguin >> I want to use Chisquare Test to test if the proportions are equal. Four sample proportions drawn from independent populations were already computed (e.g., p1=.29, p2=34, p3=.20 & p4=.23). Sample sizes were available. Can we do it in SPSS. What is the syntax? ===================== 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 |
|
The available data are the computed group proportions and sample sizes, not raw data. Im sure it can be done only through syntax. But the "help" does not provide syntax guide for this case, unless I overlooked it..
Eins. Gene Maguin <[hidden email]> wrote: Eins, I think you should look at the chisquare option under the npar command. Read up on it in the syntax reference. Gene Maguin >> I want to use Chisquare Test to test if the proportions are equal. Four sample proportions drawn from independent populations were already computed (e.g., p1=.29, p2=34, p3=.20 & p4=.23). Sample sizes were available. Can we do it in SPSS. What is the syntax? ===================== 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 --------------------------------- HOTMAIL, GMAIL, ….ACCOUNTS? Invite your friends from Hotmail, Gmail to Yahoo! Messenger today! ===================== 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 |
|
Eins,
If you can run R scripts in SPSS try prop.test Here is an example - > enter <- c(33, 346, 158, 880053) > allcrimes <- c(306, 3532, 1685, 4689106) > prop.test(enter, allcrimes) 4-sample test for equality of proportions without continuity correction data: enter out of allcrimes X-squared = 296.5336, df = 3, p-value < 2.2e-16 alternative hypothesis: two.sided sample estimates: prop 1 prop 2 prop 3 prop 4 0.10784314 0.09796149 0.09376855 0.18768034 If you have small cell sizes an exact test may be required. I had a similar problem some open to alternative suggestions. The data is number of offences rather than individual persons. Bob At 11:43 AM 11/01/2009, you wrote: >The available data are the computed group >proportions and sample sizes, not raw data. Im >sure it can be done only through syntax. But >the "help" does not provide syntax guide for >this case, unless I overlooked it.. > > Eins. > >Gene Maguin <[hidden email]> wrote: Eins, > >I think you should look at the chisquare option under the npar command. Read >up on it in the syntax reference. > >Gene Maguin > > >> I want to use Chisquare Test to test if the proportions are equal. Four >sample proportions drawn from independent populations were already computed >(e.g., p1=.29, p2=34, p3=.20 & p4=.23). Sample sizes were available. Can we >do it in SPSS. What is the syntax? > >===================== >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 > > > >--------------------------------- > HOTMAIL, GMAIL, .ACCOUNTS? >Invite your friends from Hotmail, Gmail to Yahoo! Messenger today! > >===================== >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 ===================== 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 |
|
In reply to this post by E. Bernardo
You can get confidence intervals for proportions and comparison tests from the PROPOR extension command available with SPSS version 16 or later. It calculates both binomial and Poisson intervals and tests for overlap. It works off the calculated proportions, so the raw data are not required.
This can be downloaded from SPSS Developer Central, www.spss.com/devcentral and requires the Python programmability plug-in. -----Original Message----- From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Eins Bernardo Sent: Saturday, January 10, 2009 6:43 PM To: [hidden email] Subject: Re: [SPSSX-L] test of equal proportion The available data are the computed group proportions and sample sizes, not raw data. Im sure it can be done only through syntax. But the "help" does not provide syntax guide for this case, unless I overlooked it.. Eins. Gene Maguin <[hidden email]> wrote: Eins, I think you should look at the chisquare option under the npar command. Read up on it in the syntax reference. Gene Maguin >> I want to use Chisquare Test to test if the proportions are equal. Four sample proportions drawn from independent populations were already computed (e.g., p1=.29, p2=34, p3=.20 & p4=.23). Sample sizes were available. Can we do it in SPSS. What is the syntax? ===================== 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 --------------------------------- HOTMAIL, GMAIL, ....ACCOUNTS? Invite your friends from Hotmail, Gmail to Yahoo! Messenger today! ===================== 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 ===================== 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 |
|
Hi all,
I would like to draw your attention to Bibus, an open source Endnote-like program. It works with both OpenOffice and MS Word. It's Python-based.See: http://innovation.swmed.edu/research/res_bibus.htm It seems to work well, but I just installed it so I didn't entirely figure out everything yet. If you're struggling to make the connection between OO and Bibus (like me): click C:\Program Files\bibus\SetupUnoConnectionListener.odg to enable some settings. Sorry for cross-posting, but I believe this might be of interest to you. Best wishes, Albert-Jan ===================== 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 |
|
In reply to this post by Maguin, Eugene
Dear List,
Can anyone tell me or direct me to a refernce for calculating and *intrepreting* an effect size for Cox regression? I believe this is covered in Allison 1999, but I am in the process of moving and my copy is somewhere in a box : ( Thanks in advance! John ===================== 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 |
|
In reply to this post by E. Bernardo
Ok, that's a bit tougher. If you have 15 or 16, whichever version Jon Peck
mentioned, and are familiar with python, then that is probably easier. That aside, there are two basic alternatives. 1) do it by hand. You are testing the observed proportions against the hypothesized proportions. It's the standard chisquare computation. And that's a trivial calculation. Look at any undergrad stats text (or, even better, look in the spss algorithm pdf). 2) Generate a dataset using the observed ns and proportions and run the procedure. This goes like this. Input program. Loop grp=1 to 4. * group 1: n=50, proportion=.30; 15 of 50. Do if (grp eq 1). Loop j=1 to 50. + Compute resp=0. + If (j le 15) resp=1. Leave grp j. End case. End loop. Else if (grp eq 2). * group 2: n=30, proportion=.40; 12 of 30. Loop j=1 to 30. Compute resp=0. If (j le 12) resp=1. Leave grp j. End case. End loop. Else if (grp eq 3). * group 3: n=70, proportion=.50; 35 of 70. Loop j=1 to 70. Compute resp=0. If (j le 35) resp=1. Leave grp j. End case. End loop. Else if (grp eq 4). * group 4: n=60, proportion=.25; 15 of 60. Loop j=1 to 60. Compute resp=0. If (j le 15) resp=1. Leave grp j. End case. End loop. End if. End loop. End file. End input program. Execute. Gene Maguin ===================== 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 |
|
As I mentioned offline, the PROPOR procedure is an extension command (16 or later), so no knowledge of Python is required, although you have to install Python and its plug-in.
-----Original Message----- From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Gene Maguin Sent: Sunday, January 11, 2009 12:56 PM To: [hidden email] Subject: Re: [SPSSX-L] test of equal proportion Ok, that's a bit tougher. If you have 15 or 16, whichever version Jon Peck mentioned, and are familiar with python, then that is probably easier. That aside, there are two basic alternatives. 1) do it by hand. You are testing the observed proportions against the hypothesized proportions. It's the standard chisquare computation. And that's a trivial calculation. Look at any undergrad stats text (or, even better, look in the spss algorithm pdf). 2) Generate a dataset using the observed ns and proportions and run the procedure. This goes like this. ===================== 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 |
|
In reply to this post by Maguin, Eugene
At 02:56 PM 1/11/2009, Gene Maguin wrote:
>2) [You can] generate a dataset using the observed ns and >proportions and run the procedure. This goes like this. [Input Program solution, replicating all case, not quoted here.] It's simpler to use WEIGHT rather than replicating the cases. That also lets you use parameters entered as data, rather than hard-coding them: |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Group Size Proportion 1 50 .30 2 30 .40 3 70 .50 4 60 .25 Number of cases read: 4 Number of cases listed: 4 NUMERIC Resp0 Resp1 (F4). COMPUTE Resp0 = Size*(1-Proportion). COMPUTE Resp1 = Size* Proportion. . /**/ LIST /*-*/. List |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Group Size Proportion Resp0 Resp1 1 50 .30 35 15 2 30 .40 18 12 3 70 .50 35 35 4 60 .25 45 15 Number of cases read: 4 Number of cases listed: 4 VARSTOCASES /MAKE Count FROM Resp0 Resp1 /INDEX = Response(2) /KEEP = Group /NULL = KEEP. Variables to Cases |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Generated Variables |--------|------| |Name |Label | |--------|------| |Response|<none>| |Count |<none>| |--------|------| Processing Statistics |-------------|-| |Variables In |5| |Variables Out|3| |-------------|-| COMPUTE Response = Response - 1. LIST. List |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Group Response Count 1 0 35 1 1 15 2 0 18 2 1 12 3 0 35 3 1 35 4 0 45 4 1 15 Number of cases read: 8 Number of cases listed: 8 WEIGHT BY Count. ============================= APPENDIX: Test data, and code ============================= DATA LIST LIST/ Group Size Proportion (F3, F4, F5.2). * group 1: n=50, proportion=.30; 15 of 50. * group 2: n=30, proportion=.40; 12 of 30. * group 3: n=70, proportion=.50; 35 of 70. * group 4: n=60, proportion=.25; 15 of 60. BEGIN DATA 1 50 .30 2 30 .40 3 70 .50 4 60 .25 END DATA. LIST. NUMERIC Resp0 Resp1 (F4). COMPUTE Resp0 = Size*(1-Proportion). COMPUTE Resp1 = Size* Proportion. . /**/ LIST /*-*/. VARSTOCASES /MAKE Count FROM Resp0 Resp1 /INDEX = Response(2) /KEEP = Group /NULL = KEEP. COMPUTE Response = Response - 1. LIST. WEIGHT BY Count. ===================== 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 |
|
Many thanks to everyone. Your suggestions are hepful.
Eins Richard Ristow <[hidden email]> wrote: At 02:56 PM 1/11/2009, Gene Maguin wrote: >2) [You can] generate a dataset using the observed ns and >proportions and run the procedure. This goes like this. [Input Program solution, replicating all case, not quoted here.] It's simpler to use WEIGHT rather than replicating the cases. That also lets you use parameters entered as data, rather than hard-coding them: |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Group Size Proportion 1 50 .30 2 30 .40 3 70 .50 4 60 .25 Number of cases read: 4 Number of cases listed: 4 NUMERIC Resp0 Resp1 (F4). COMPUTE Resp0 = Size*(1-Proportion). COMPUTE Resp1 = Size* Proportion. .. /**/ LIST /*-*/. List |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Group Size Proportion Resp0 Resp1 1 50 .30 35 15 2 30 .40 18 12 3 70 .50 35 35 4 60 .25 45 15 Number of cases read: 4 Number of cases listed: 4 VARSTOCASES /MAKE Count FROM Resp0 Resp1 /INDEX = Response(2) /KEEP = Group /NULL = KEEP. Variables to Cases |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Generated Variables |--------|------| |Name |Label | |--------|------| |Response|| |Count || |--------|------| Processing Statistics |-------------|-| |Variables In |5| |Variables Out|3| |-------------|-| COMPUTE Response = Response - 1. LIST. List |-----------------------------|---------------------------| |Output Created |12-JAN-2009 03:36:23 | |-----------------------------|---------------------------| Group Response Count 1 0 35 1 1 15 2 0 18 2 1 12 3 0 35 3 1 35 4 0 45 4 1 15 Number of cases read: 8 Number of cases listed: 8 WEIGHT BY Count. ============================= APPENDIX: Test data, and code ============================= DATA LIST LIST/ Group Size Proportion (F3, F4, F5.2). * group 1: n=50, proportion=.30; 15 of 50. * group 2: n=30, proportion=.40; 12 of 30. * group 3: n=70, proportion=.50; 35 of 70. * group 4: n=60, proportion=.25; 15 of 60. BEGIN DATA 1 50 .30 2 30 .40 3 70 .50 4 60 .25 END DATA. LIST. NUMERIC Resp0 Resp1 (F4). COMPUTE Resp0 = Size*(1-Proportion). COMPUTE Resp1 = Size* Proportion. .. /**/ LIST /*-*/. VARSTOCASES /MAKE Count FROM Resp0 Resp1 /INDEX = Response(2) /KEEP = Group /NULL = KEEP. COMPUTE Response = Response - 1. LIST. WEIGHT BY Count. ===================== 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 --------------------------------- Get your preferred Email name! Now you can @ymail.com and @rocketmail.com. ===================== 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 |
|
In reply to this post by Peck, Jon
Hi all,
Do you have references about the predictors of admitted student applicants to enroll in a university?. I am doing some literature review for the factors affecting the decision of admitted applicant to enroll or not in a school. Eins --------------------------------- How do you prepare for your first job interview? Discover the different ways in Yahoo! Answers! ===================== 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 |
|
In reply to this post by Richard Ristow
Thanks to all the pointed out a much, much simpler way to work Ein's
problem. I'll need to remember this for the future. Gene Maguin ===================== 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 |
| Free forum by Nabble | Edit this page |
