2 ways to import count data but get different results from Poisson Regression

  • Follow


Hi SAS users,

   When I analyze the rate of injury by hospital teaching status. I
calculate the average injury rates by teaching status:
                             Rate                        Rate ratio
     Teaching           26/1000 FTEs           26/18 = 1.44
     Non-teaching     18/1000 FTEs           reference

   I have tried two ways (there could be more ways) to import the
injury count data into SAS.
   OPTION 1: use SAS datalines option such as:
                    data data1;
                    input teaching count total_fte;
                    l_fte=log(total_fte);
                   datalines;
                   No 6041 332967.7441
                   Yes 12778 490319.0468
                   ;
                   run;
       *This option is simple, but doesn't allow a more complicated
model multivariate testing.

   OPTION 2: use count dataset that include breakdown of all
variables, such as:
                   year quarter count total_fte teaching bedcat ....
                   2002   3         23     2345       No
1   .....
                   2004   1        100  100322     Yes
2   .....
       *This option does allow a more complicated model multivariate
testing.

    When I fit the data from either OPTION into a Poisson model, an
crude univariate poisson regression model for the association between
injury rate and teaching status shows that the model rate ratio from
OPTION 1 is 1.44, model rate ratio from OPTION 2 is 1.33. I don't
understand why the crude model rate ratio for OPTION 2 isn't 1.44 like
the observed rate ratio or  OPTION 1??? Any thoughts on this? Thank
you.


Vivian
0
Reply Vivian 12/28/2009 10:28:52 PM

Vivian,

You didn't show your code, thus the best I can do is an educated guess.

If I understand, correctly, you are analyzing rate/frequency data,
aggregated at two different levels.

My guess is that you didn't weight the analyses, by FTE, in one or both
analyses.  I would presume that, if you did, you would get the same results.

Art
-------
On Mon, 28 Dec 2009 14:28:52 -0800, Vivian Pun <vivianpun09@GMAIL.COM>
wrote:

>Hi SAS users,
>
>   When I analyze the rate of injury by hospital teaching status. I
>calculate the average injury rates by teaching status:
>                             Rate                        Rate ratio
>     Teaching           26/1000 FTEs           26/18 = 1.44
>     Non-teaching     18/1000 FTEs           reference
>
>   I have tried two ways (there could be more ways) to import the
>injury count data into SAS.
>   OPTION 1: use SAS datalines option such as:
>                    data data1;
>                    input teaching count total_fte;
>                    l_fte=log(total_fte);
>                   datalines;
>                   No 6041 332967.7441
>                   Yes 12778 490319.0468
>                   ;
>                   run;
>       *This option is simple, but doesn't allow a more complicated
>model multivariate testing.
>
>   OPTION 2: use count dataset that include breakdown of all
>variables, such as:
>                   year quarter count total_fte teaching bedcat ....
>                   2002   3         23     2345       No
>1   .....
>                   2004   1        100  100322     Yes
>2   .....
>       *This option does allow a more complicated model multivariate
>testing.
>
>    When I fit the data from either OPTION into a Poisson model, an
>crude univariate poisson regression model for the association between
>injury rate and teaching status shows that the model rate ratio from
>OPTION 1 is 1.44, model rate ratio from OPTION 2 is 1.33. I don't
>understand why the crude model rate ratio for OPTION 2 isn't 1.44 like
>the observed rate ratio or  OPTION 1??? Any thoughts on this? Thank
>you.
>
>
>Vivian
0
Reply art297 (4237) 12/29/2009 1:36:43 AM


Vivian,

Please show the code which you employed to fit your Poisson
models to the data for each of your two options.

I presume that for option 1, your code was something like:

proc genmod data=data1;
  class teaching;
  model count = teaching / offset=l_fte dist=poisson;
run;

Is that correct?

Dale

---------------------------------------
Dale McLerran
Fred Hutchinson Cancer Research Center
mailto: dmclerra@NO_SPAMfhcrc.org
Ph:  (206) 667-2926
Fax: (206) 667-5977
---------------------------------------


--- On Mon, 12/28/09, Vivian Pun <vivianpun09@GMAIL.COM> wrote:

> From: Vivian Pun <vivianpun09@GMAIL.COM>
> Subject: 2 ways to import count data but get different results from              Poisson Regression
> To: SAS-L@LISTSERV.UGA.EDU
> Date: Monday, December 28, 2009, 2:28 PM
> Hi SAS users,
>
>    When I analyze the rate of injury by hospital teaching status. I
> calculate the average injury rates by teaching status:
>
>                             Rate                 Rate ratio
>      Teaching           26/1000 FTEs           26/18 = 1.44
>      Non-teaching       18/1000 FTEs           reference
>
>    I have tried two ways (there could be more ways) to import the
> injury count data into SAS.
>    OPTION 1: use SAS datalines option such as:
>
>     data data1;
>     input teaching count total_fte;
>     l_fte=log(total_fte);
>    datalines;
>    No 6041 332967.7441
>    Yes 12778 490319.0468
>    ;
>
>    run;
>        *This option is simple, but doesn't allow a more complicated
> model multivariate testing.
>
>    OPTION 2: use count dataset that include breakdown of all
> variables, such as:
>
>    year quarter count total_fte teaching bedcat ....
>
>    2002   3         23     2345       No 1   .....
>    2004   1        100   100322      Yes 2   .....
>        *This option does allow a more complicated model multivariate
> testing.
>
>     When I fit the data from either OPTION into a Poisson model, an
> crude univariate poisson regression model for the association between
> injury rate and teaching status shows that the model rate ratio from
> OPTION 1 is 1.44, model rate ratio from OPTION 2 is 1.33. I don't
> understand why the crude model rate ratio for OPTION 2 isn't 1.44 like
> the observed rate ratio or  OPTION 1??? Any thoughts on this? Thank
> you.
>
>
> Vivian
>
0
Reply stringplayer_2 (1472) 12/29/2009 1:40:54 AM

On Dec 28, 5:28=A0pm, Vivian Pun <vivianpu...@gmail.com> wrote:
> Hi SAS users,
>
> =A0 =A0When I analyze the rate of injury by hospital teaching status. I
> calculate the average injury rates by teaching status:
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0Rate =A0 =A0 =
=A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0Rate ratio
> =A0 =A0 =A0Teaching =A0 =A0 =A0 =A0 =A0 26/1000 FTEs =A0 =A0 =A0 =A0 =A0 =
26/18 =3D 1.44
> =A0 =A0 =A0Non-teaching =A0 =A0 18/1000 FTEs =A0 =A0 =A0 =A0 =A0 referenc=
e
>
> =A0 =A0I have tried two ways (there could be more ways) to import the
> injury count data into SAS.
> =A0 =A0OPTION 1: use SAS datalines option such as:
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 data data1;
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 input teaching count total_fte;
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 l_fte=3Dlog(total_fte);
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0datalines;
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0No 6041 332967.7441
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0Yes 12778 490319.0468
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0;
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0run;
> =A0 =A0 =A0 =A0*This option is simple, but doesn't allow a more complicat=
ed
> model multivariate testing.
>
> =A0 =A0OPTION 2: use count dataset that include breakdown of all
> variables, such as:
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0year quarter count total_fte teach=
ing bedcat ....
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A02002 =A0 3 =A0 =A0 =A0 =A0 23 =A0 =
=A0 2345 =A0 =A0 =A0 No
> 1 =A0 .....
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A02004 =A0 1 =A0 =A0 =A0 =A0100 =A01=
00322 =A0 =A0 Yes
> 2 =A0 .....
> =A0 =A0 =A0 =A0*This option does allow a more complicated model multivari=
ate
> testing.
>
> =A0 =A0 When I fit the data from either OPTION into a Poisson model, an
> crude univariate poisson regression model for the association between
> injury rate and teaching status shows that the model rate ratio from
> OPTION 1 is 1.44, model rate ratio from OPTION 2 is 1.33. I don't
> understand why the crude model rate ratio for OPTION 2 isn't 1.44 like
> the observed rate ratio or =A0OPTION 1??? Any thoughts on this? Thank
> you.

For OPTION 1, my procedure code is

proc genmod data=3Ddata1;
class teaching (ref=3D'No') / param=3Dref;
model count =3D teaching /dist=3Dpoisson link=3Dlog offset=3Dl_fte ;
estimate 'Teaching' teaching 1/ exp;
run;

for OPTION 2,
proc genmod data=3Ddata;
class hosid teaching (ref=3D'No') / param=3Dref;
model count =3D teaching /dist=3Dpoisson link=3Dlog offset=3Dl_fte ;
repeated subject =3D hosid;
estimate 'Teaching' teaching 1/ exp;
run;

(for option 2, because my surveillance data spans for 7 years and same
99 hospitals (hosid) each year, I use repeated measurement for
hospitals.)
Does it make sense?? Any thoughts on why the results from both OPTIONS
using the same data differ?? Thank you.



Vivian
0
Reply Vivian 12/29/2009 1:27:20 PM

3 Replies
213 Views

(page loaded in 0.064 seconds)

Similiar Articles:








7/19/2012 8:20:28 PM


Reply: