Hello all,
I should start by saying my background in stats is limited, but I would like to expand on it. I notice that there are some very sophisticated questions on this list...so I reluctantly ask mine. I have a very basic stats question about how to determine differences between groups using a the chi-square statistic available during a cross- tabulation analysis in spss. Heres a description of the data I am working with: Variable1 (status): 3 Categories = User, Former User, Never User Variable2 (education): 5 Categories = Less than Secondary, Secondary, College, University, Other I ran a crosstabs on this and selected the chi-square statistic. Here is the pasted syntax: CROSSTABS /TABLES= STATUS BY EDUCLV /FORMAT= AVALUE TABLES /STATISTIC=CHISQ /CELLS= COUNT ROW COLUMN TOTAL /COUNT ROUND CELL . The output tells me that there is a significant difference between groups. So here's my basic question: how do I find out exactly where that difference is? Do I need to run a different type of analysis (NPAR/Kruskal- Wallis)? Seiph |
Seiph,
I am sure there are more experienced folks on these matters than I am on this list, but let me make a couple of remarks. First, I would not use Kruskal-Wallis because you are dealing with categorical variables, even though one of them is ordinal (but ordinal categorical). The KW test is best used when your dependent variable is quantitative and the assumptions for a one-way ANOVA are not met. Second, the chi-square test does not take advantage of the ordinal information that is inherent in your educational level variable. Your data would probably be better analyzed using a logit model with the dependent (outcome) variable User (3 categories) and Education (3 categories) as the predictor (independent) variable. You access this type of model under Analyze>Loglinear>Logit. Perhaps you will hear from other folks on the list who can give more detailed guidance. Good luck. Dominic Dominic Lusinchi Statistician Far West Research Statistical Consulting San Francisco, California 415-664-3032 www.farwestresearch.com -----Original Message----- From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Seiph Sent: Tuesday, September 12, 2006 9:06 AM To: [hidden email] Subject: Chi-square Hello all, I should start by saying my background in stats is limited, but I would like to expand on it. I notice that there are some very sophisticated questions on this list...so I reluctantly ask mine. I have a very basic stats question about how to determine differences between groups using a the chi-square statistic available during a cross- tabulation analysis in spss. Here's a description of the data I am working with: Variable1 (status): 3 Categories = User, Former User, Never User Variable2 (education): 5 Categories = Less than Secondary, Secondary, College, University, Other I ran a crosstabs on this and selected the chi-square statistic. Here is the pasted syntax: CROSSTABS /TABLES= STATUS BY EDUCLV /FORMAT= AVALUE TABLES /STATISTIC=CHISQ /CELLS= COUNT ROW COLUMN TOTAL /COUNT ROUND CELL . The output tells me that there is a significant difference between groups. So here's my basic question: how do I find out exactly where that difference is? Do I need to run a different type of analysis (NPAR/Kruskal- Wallis)? Seiph |
In reply to this post by Seiph
I'm struggling through OMS syntax and the related commands
in the Python spssaux module: "CreateXMLOutput" and "GetValuesFromXMLWorkspace". My questions have to do with the extent(s) to which a "tagged" XML workspace survives (is available for use) after: (1) a change in platform: For example, suppose spss syntax *embedded* in a Python procedure directs SPSS output to a "tagged" XML workspace. How long is info in the workspace available to the Python procedure? (2) an embedded SPSS "OMSEND" or (3) a Python/spssaux "spss.DeleteXPathHandle(handle) command? Gary --- Gary Rosin <[hidden email]> "The world is stronger than ideas about the world." --Linda Gregg |
In reply to this post by Seiph
At 12:06 PM 9/12/2006, Seiph wrote:
>I have a very basic stats question about how to determine differences >between groups using a the chi-square statistic available during a >cross-tabulation analysis in spss. > >I ran a crosstabs and selected the chi-square statistic. Here is the >pasted syntax: >CROSSTABS > /TABLES= STATUS BY EDUCLV > /FORMAT= AVALUE TABLES > /STATISTIC=CHISQ > /CELLS= COUNT ROW COLUMN TOTAL > /COUNT ROUND CELL . > >The output tells me that there is a significant difference between >groups. So here's my basic question: how do I find out exactly where >that difference is? Try adding, to subcommand CELLS, EXPECTED and ASRESID. (That puts a lot of numbers in each cell; you may want to drop one or more of the percents.) EXPECTED is the expected number in the cell, if the null hypothesis is correct, and ASRESID is the adjusted standardized difference from observed and expected. Look for cells with ASRESID greater than 2 in absolute value; that will show cells where the difference is most important. (Marta, do I have this wrong in any way?) |
Hi all,
Is there any way to evaluate multicollinearity or collinearity after running Cox regression analysis with SPSS? Thansk, /Christian |
In reply to this post by Richard Ristow
Hi Richard
>>I have a very basic stats question about how to determine differences >>between groups using a the chi-square statistic available during a >>cross-tabulation analysis in spss. >> >>I ran a crosstabs and selected the chi-square statistic. Here is the >>pasted syntax: >>CROSSTABS >> /TABLES= STATUS BY EDUCLV >> /FORMAT= AVALUE TABLES >> /STATISTIC=CHISQ >> /CELLS= COUNT ROW COLUMN TOTAL >> /COUNT ROUND CELL . >> >>The output tells me that there is a significant difference between >>groups. So here's my basic question: how do I find out exactly where >>that difference is? RR> Try adding, to subcommand CELLS, EXPECTED and ASRESID. (That puts a lot RR> of numbers in each cell; you may want to drop one or more of the RR> percents.) RR> EXPECTED is the expected number in the cell, if the null hypothesis is RR> correct, and ASRESID is the adjusted standardized difference from RR> observed and expected. Look for cells with ASRESID greater than 2 in RR> absolute value; that will show cells where the difference is most RR> important. RR> (Marta, do I have this wrong in any way?) Gooody good (all OK). -- Regards, Dr. Marta García-Granero,PhD mailto:[hidden email] Statistician --- "It is unwise to use a statistical procedure whose use one does not understand. SPSS syntax guide cannot supply this knowledge, and it is certainly no substitute for the basic understanding of statistics and statistical thinking that is essential for the wise choice of methods and the correct interpretation of their results". (Adapted from WinPepi manual - I'm sure Joe Abrahmson will not mind) |
In reply to this post by cbautista
Hi Christian
CB> Is there any way to evaluate multicollinearity or collinearity after CB> running Cox regression analysis with SPSS? Use multiple linear regression (use time variable as DV, ignore the coefficients, and ask for all collinearity statistics). -- Regards, Dr. Marta García-Granero,PhD mailto:[hidden email] Statistician --- "It is unwise to use a statistical procedure whose use one does not understand. SPSS syntax guide cannot supply this knowledge, and it is certainly no substitute for the basic understanding of statistics and statistical thinking that is essential for the wise choice of methods and the correct interpretation of their results". (Adapted from WinPepi manual - I'm sure Joe Abrahmson will not mind) |
Thanks Martha,
Assume that this method is stiil valid with independent categoric variables, right? I remember that other mesuare to evaluate the presence of collinearity apart of Torelance and VIF is "condition number", is there any way to get this one with SPSS? Thanks in advance, /Christian Marta García-Granero <biostatistics@te To rra.es> [hidden email] Sent by: cc "SPSSX(r) Discussion" Subject <SPSSX-L@LISTSERV Re: evaluation multicollineary in .UGA.EDU> Cox regression 09/14/2006 02:10 PM Please respond to Marta García-Granero <biostatistics@te rra.es> Hi Christian CB> Is there any way to evaluate multicollinearity or collinearity after CB> running Cox regression analysis with SPSS? Use multiple linear regression (use time variable as DV, ignore the coefficients, and ask for all collinearity statistics). -- Regards, Dr. Marta García-Granero,PhD mailto:[hidden email] Statistician --- "It is unwise to use a statistical procedure whose use one does not understand. SPSS syntax guide cannot supply this knowledge, and it is certainly no substitute for the basic understanding of statistics and statistical thinking that is essential for the wise choice of methods and the correct interpretation of their results". (Adapted from WinPepi manual - I'm sure Joe Abrahmson will not mind) |
Hi Christian
CB> Assume that this method is stiil valid with independent categoric CB> variables, right? If they are binary, yes, if they are politomous, then you have to create manually the set of dummy variables, because Linear Regression doesn't handle them. See this example (assuming a qualitative predictors with 3 categories, numbered 1,2,3 and called "qualitvar"): DO REPEAT A= dummy1 dummy2 /B= 2 3. - COMPUTE A=(qualitvar=B). END REPEAT. Use dummy1 and dummy2 instead of qualitvar in the regression analysis. CB> I remember that other mesuare to evaluate the presence of collinearity CB> apart of Torelance and VIF is "condition number", is there any way to get CB> this one with SPSS? Condition index? it is part of SPSS output. -- Regards, Dr. Marta García-Granero,PhD mailto:[hidden email] Statistician --- "It is unwise to use a statistical procedure whose use one does not understand. SPSS syntax guide cannot supply this knowledge, and it is certainly no substitute for the basic understanding of statistics and statistical thinking that is essential for the wise choice of methods and the correct interpretation of their results". (Adapted from WinPepi manual - I'm sure Joe Abrahmson will not mind) |
In reply to this post by Gary Rosin
-----Original Message-----
From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Gary Rosin Sent: Tuesday, September 12, 2006 3:17 PM To: [hidden email] Subject: [SPSSX-L] availability of XML workspaces I'm struggling through OMS syntax and the related commands in the Python spssaux module: "CreateXMLOutput" and "GetValuesFromXMLWorkspace". My questions have to do with the extent(s) to which a "tagged" XML workspace survives (is available for use) after: (1) a change in platform: For example, suppose spss syntax *embedded* in a Python procedure directs SPSS output to a "tagged" XML workspace. How long is info in the workspace available to the Python procedure? [>>>Peck, Jon] The XMLWorkspace exists for the duration of your SPSS session, although switching to distributed mode (SPSS Server) counts as a new session. The workspace lives in memory (2) an embedded SPSS "OMSEND" or [>>>Peck, Jon] OMS items are placed in the workspace only at OMSEND for an appropriate request. This timing is the same as if you wrote to a file or dataset. (3) a Python/spssaux "spss.DeleteXPathHandle(handle) command? [>>>Peck, Jon] That will kill the item from the workspace CreateXMLOutput returns a handle to the item in the workspace. It wraps your syntax in appropriate OMS commands, but you need to specify the items to select if the default won't work. GetValuesFromXMLWorkspace uses that tag that the previous call returned, but it does not remove anything from the workspace. You can get a listing of all the current tags in the workspace with spss.GetHandleList HTH, Jon Peck (on vacation) Gary --- Gary Rosin <[hidden email]> "The world is stronger than ideas about the world." --Linda Gregg |
[>>>Peck, Jon] OMS items are placed in the workspace only at
OMSEND for an appropriate request. This timing is the same as if you wrote to a file or dataset. Thanks, I had thought that each embedded spss operation automatically sent to the XML workspace **until** OMSEND. Does the CreateXMLOutput command in spssaux work the same way? The examples in Chapter 16 of Ray Levesque's "SPSS Programming and Data Management, 3rd Ed." suggests that it might. FYI, I'm using the XML workspace to test for convergence of a regression statistic in a iterated WLS loop. I need to write to the XML workspace during each iteration. Beginning with the second iteration, I then need to test for convergence to see if I can "break" out of the loop. Gary |
CreateXMLOutput actually uses OMS commands, so its logic is the same as OMS, although it wraps all this up more simply.
I gather that you are iterating the WLS procedure or the equivalent. So the natural approach would be to put CreateXMLOutput/GetValuesFromXMLWorkspace in your loop and terminate when the criteria are met. (You might want to delete the items each time through as well. HTH, Jon Peck -----Original Message----- From: SPSSX(r) Discussion [mailto:[hidden email]] On Behalf Of Gary Rosin Sent: Friday, September 15, 2006 1:54 PM To: [hidden email] Subject: Re: [SPSSX-L] availability of XML workspaces [>>>Peck, Jon] OMS items are placed in the workspace only at OMSEND for an appropriate request. This timing is the same as if you wrote to a file or dataset. Thanks, I had thought that each embedded spss operation automatically sent to the XML workspace **until** OMSEND. Does the CreateXMLOutput command in spssaux work the same way? The examples in Chapter 16 of Ray Levesque's "SPSS Programming and Data Management, 3rd Ed." suggests that it might. FYI, I'm using the XML workspace to test for convergence of a regression statistic in a iterated WLS loop. I need to write to the XML workspace during each iteration. Beginning with the second iteration, I then need to test for convergence to see if I can "break" out of the loop. Gary |
Free forum by Nabble | Edit this page |