turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Find a Community

- Home
- /
- Analytics
- /
- Stat Procs
- /
- Proc genmod effect of using an offset on LSmeans

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

2 weeks ago

Hello,

I am currently running a proc genmod with poisson distribution on a dataset and was looking for LSmeans estimated for one of the variables.

When I do this without an offset included and I ask to transform the LSmeans back to response scale (ilink) I get estimates that make intuitive sense (on the correct scale of the original count variable).

However when I include an offset in the model (based on the log of another variable), the LSmeans seem to be presented on a different scale, even with the ilink option included. Results are strongly correlated though.

So I was wondering what exactly is happening in the LSmeans estimation when an offset is included in the model. And additionaly how to get the LSmeans back to response scale with an offset included in the model.

Ideally I want to get estimates on the original count scale with an offset included in the model.

model with offset:

ods output LSmeans=LSmeans;

proc genmod data=control;

class F2 block ;

model eggs = F2 block / type3 dist=poisson offset=l_area;

lsmeans F2/cl ilink;run;quit;

model without offset:

ods output LSmeans=LSmeans1;

proc genmod data=control;

class F2 block ;

model eggs = F2 block / type3 dist=poisson ;

lsmeans F2/cl ilink;run;quit;

The first model produces LSmeans with the following values for the "mean" column in the LSmeans output:

0.04437

0.07704

0.03344

0.03425

0.02408

0.05762

The second model produces LSmeans with the following values for the "mean" column in the LSmeans output:

9.2543

15.1355

9.9462

6.5443

4.8722

10.4939

Thank you in advance.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

2 weeks ago - last edited 2 weeks ago

lsmeans age / ilink diff exp cl ;

I think that is what supposed to be,

offset= will offset a value from mean of population.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

2 weeks ago

Thank you for replying, but this does not seem to translate the marginal averages back to the original count scale.

From what I understand, this is just the way it is and I have to interpret the results on a rate scale instead of the original count scale.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

2 weeks ago

When you use an offset, you are modeling *rate* (eggs/area) rather than *count *(eggs). See the example here:

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

2 weeks ago

This is also what I have found, there seems to be no transformation back to the original count scale available.

I will just have to work with that scale in my results (which is also reasonable).

Thank you

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

2 weeks ago

I'll admit, it's not clear to me why you would model rate (eggs/area) but want estimates of count (eggs). The only scenario in which that makes sense is when area is the same for every observation. If area differs among observations then, really, what are you to make of count data? I don't see the logic in that. You note that rate is "reasonable" so that's probably the path you should follow.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Highlight
- Email to a Friend
- Report Inappropriate Content

2 weeks ago

The desire to present the results on the count scale comes from a customer. And I have at least to try to accomodate their wishes.