# negative binomial regression

9 messages
Open this post in threaded view
|

## negative binomial regression

 urgent help needed: I am using SPSS 25 to perform a negative binomial regression on overdispersed data. I am trying to work out the negative binomial equation/interpretation (582 wards are columns; variables are rows) = Dependent variable is Deaths 2011 (numeric figure for each 582 wards) + Independent variables are: categorical treated as factors and the rest are % proportions treated as covariates. My Q: controlling for demographics and health variables, it was hypothesised than an increase in an areas deprivation and farming activities will statistically increase the risk of ward mortality. 1. How do I make predictions of deaths as I am at my wits end trying to figure it out!! Going around and round in circles and getting nowhere :C 2. The code I am running is not doing what I want it to. I want to look at deprivation (NIMDM) at 1 (most deprived, and then at other intervals for comparisons) and see what the predicted deaths are in wards and its influence this has on the other IVs. But when I run this code below it makes no difference to running it without the       /EMMEANS CONTROL=NIMDMrank2010(1) line 3. Then trying to place them on a scatterplot for comparisons. But when I run this code which of the 4 variables created do I plot (if any). i know XPPRED gives me the predicted log counts but how do I make them meaningful in a figure. GENLIN deaths11_fig BY farms11code avSOfarm_abovBEL grass_NEW crops_NEW catttle11code sheep11code     pigs11code poultry11code (ORDER=DESCENDING) WITH pcnt65to100A SEXmalprcnt11 tot_livalone11 Qbeldeg     FT31plushrs NIMDMrank2010 yesUNPcar LLTIyesTOT OCCprcnt51 LFAfarms11 FARMEDpcnt_NEW   /MODEL farms11code avSOfarm_abovBEL grass_NEW crops_NEW catttle11code sheep11code pigs11code     poultry11code pcnt65to100A SEXmalprcnt11 tot_livalone11 Qbeldeg FT31plushrs NIMDMrank2010 yesUNPcar     LLTIyesTOT OCCprcnt51 LFAfarms11 FARMEDpcnt_NEW INTERCEPT=YES OFFSET=NL_popul11  DISTRIBUTION=NEGBIN(MLE) LINK=LOG   /CRITERIA METHOD=FISHER(1) SCALE=1 COVB=ROBUST MAXITERATIONS=1000 MAXSTEPHALVING=50     PCONVERGE=1E-006(ABSOLUTE) SINGULAR=1E-012 ANALYSISTYPE=3(WALD) CILEVEL=95 CITYPE=WALD     LIKELIHOOD=FULL       /EMMEANS CONTROL=NIMDMrank2010(1)   /MISSING CLASSMISSING=EXCLUDE   /PRINT CPS DESCRIPTIVES MODELINFO FIT SUMMARY SOLUTION (EXPONENTIATED)     /SAVE MEANPRED XBPRED COOK DEVIANCERESID. I am hoping someone on here knows the syntax or point-and-click method to solve this issue as I have exhausted youtube videos and reading SPSS syntax books and journals, perhaps someone knows the solution off-hand, thanks in advance for any advice, feel free to ask any questions, Kel -- Sent from: http://spssx-discussion.1045642.n5.nabble.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
Open this post in threaded view
|

## Re: negative binomial regression

Open this post in threaded view
|

## Re: negative binomial regression

Open this post in threaded view
|

## Re: negative binomial regression

Open this post in threaded view
|

## Re: negative binomial regression

Open this post in threaded view
|

## Re: negative binomial regression

 In reply to this post by keltre19 I hope these answers help as I tried to keep them as brief as possible, Thank you all for the kind suggestions, Kelly Hello Bruce, yes, I have seen the example on UCLA website, it was the most informative website of all I found on the net, however they used an older version of SPSS (ver. 19) I am running version 25, the syntax doesn’t work the way I want it unfortunately, it must be missing something small within it (im thinking due to software updates the syntax was modified) - I want to look at deprivation (NIMDM) held at 1 (its most deprived ranking, and then at other rankings for comparisons) and see what the predicted deaths are in wards and its influence this has on the other IVs. GENLIN deaths11_fig BY farms11code avSOfarm_abovBEL grass_NEW crops_NEW catttle11code sheep11code     pigs11code poultry11code (ORDER=DESCENDING) WITH pcnt65to100A SEXmalprcnt11 tot_livalone11 Qbeldeg     FT31plushrs NIMDMrank2010 yesUNPcar LLTIyesTOT OCCprcnt51 LFAfarms11 FARMEDpcnt_NEW   /MODEL farms11code avSOfarm_abovBEL grass_NEW crops_NEW catttle11code sheep11code pigs11code     poultry11code pcnt65to100A SEXmalprcnt11 tot_livalone11 Qbeldeg FT31plushrs NIMDMrank2010 yesUNPcar     LLTIyesTOT OCCprcnt51 LFAfarms11 FARMEDpcnt_NEW INTERCEPT=YES OFFSET=NL_popul11  DISTRIBUTION=NEGBIN(MLE) LINK=LOG   /CRITERIA METHOD=FISHER(1) SCALE=1 COVB=ROBUST MAXITERATIONS=1000 MAXSTEPHALVING=50     PCONVERGE=1E-006(ABSOLUTE) SINGULAR=1E-012 ANALYSISTYPE=3(WALD) CILEVEL=95 CITYPE=WALD     LIKELIHOOD=FULL       /EMMEANS CONTROL=NIMDMrank2010(1)   /MISSING CLASSMISSING=EXCLUDE   /PRINT CPS DESCRIPTIVES MODELINFO FIT SUMMARY SOLUTION (EXPONENTIATED)     /SAVE MEANPRED XBPRED COOK DEVIANCERESID. The rest of the code seems to work for me, however it is when I include the line   /EMMEANS CONTROL=NIMDMrank2010(1)    it doesn’t seem to do what I need it to, Hello Eugene and David, Yes, it does seem different to the norm but I am using the 582 ward geographical areas and treating them the same as an individual or ID (I just included this line in the initial description to show the layout of my data), So I did transpose this dataset (wards = rows; variables = columns) it will give me the characteristics of each of the 582 areas within each ward (for descriptives) but this will not allow me then to carry out the negative binomial regression as I only have the ward as variable names in rows therefore I don’t think transposing is a viable option, keeping it in its original format does overlap with the dataset layout on UCLA website, -- Sent from: http://spssx-discussion.1045642.n5.nabble.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
Open this post in threaded view
|

## Re: negative binomial regression

 Would you tell us about this study please, particularly the design and definition of "ward" and of the DV, deaths11_fig. I could pretty easily be wrong but I think there's some things we (me, especially) don’t understand. Gene Maguin -----Original Message----- From: SPSSX(r) Discussion <[hidden email]> On Behalf Of keltre19 Sent: Tuesday, May 21, 2019 6:44 AM To: [hidden email] Subject: Re: negative binomial regression I hope these answers help as I tried to keep them as brief as possible, Thank you all for the kind suggestions, Kelly Hello Bruce, yes, I have seen the example on UCLA website, it was the most informative website of all I found on the net, however they used an older version of SPSS (ver. 19) I am running version 25, the syntax doesn’t work the way I want it unfortunately, it must be missing something small within it (im thinking due to software updates the syntax was modified) - I want to look at deprivation (NIMDM) held at 1 (its most deprived ranking, and then at other rankings for comparisons) and see what the predicted deaths are in wards and its influence this has on the other IVs. GENLIN deaths11_fig BY farms11code avSOfarm_abovBEL grass_NEW crops_NEW catttle11code sheep11code     pigs11code poultry11code (ORDER=DESCENDING) WITH pcnt65to100A SEXmalprcnt11 tot_livalone11 Qbeldeg     FT31plushrs NIMDMrank2010 yesUNPcar LLTIyesTOT OCCprcnt51 LFAfarms11 FARMEDpcnt_NEW   /MODEL farms11code avSOfarm_abovBEL grass_NEW crops_NEW catttle11code sheep11code pigs11code     poultry11code pcnt65to100A SEXmalprcnt11 tot_livalone11 Qbeldeg FT31plushrs NIMDMrank2010 yesUNPcar     LLTIyesTOT OCCprcnt51 LFAfarms11 FARMEDpcnt_NEW INTERCEPT=YES OFFSET=NL_popul11  DISTRIBUTION=NEGBIN(MLE) LINK=LOG   /CRITERIA METHOD=FISHER(1) SCALE=1 COVB=ROBUST MAXITERATIONS=1000 MAXSTEPHALVING=50     PCONVERGE=1E-006(ABSOLUTE) SINGULAR=1E-012 ANALYSISTYPE=3(WALD) CILEVEL=95 CITYPE=WALD     LIKELIHOOD=FULL       /EMMEANS CONTROL=NIMDMrank2010(1)   /MISSING CLASSMISSING=EXCLUDE   /PRINT CPS DESCRIPTIVES MODELINFO FIT SUMMARY SOLUTION (EXPONENTIATED)     /SAVE MEANPRED XBPRED COOK DEVIANCERESID. The rest of the code seems to work for me, however it is when I include the line /EMMEANS CONTROL=NIMDMrank2010(1)  it doesn’t seem to do what I need it to, Hello Eugene and David, Yes, it does seem different to the norm but I am using the 582 ward geographical areas and treating them the same as an individual or ID (I just included this line in the initial description to show the layout of my data), So I did transpose this dataset (wards = rows; variables = columns) it will give me the characteristics of each of the 582 areas within each ward (for descriptives) but this will not allow me then to carry out the negative binomial regression as I only have the ward as variable names in rows therefore I don’t think transposing is a viable option, keeping it in its original format does overlap with the dataset layout on UCLA website, -- Sent from: http://spssx-discussion.1045642.n5.nabble.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 ===================== 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