Questions tagged [offset]

A variable with a fixed coefficient of 1. Offsets are commonly used in Poisson regression to allow the modeling of rates instead of counts.

A variable with a fixed coefficient of 1. Offsets are commonly used in Poisson regression to allow the modeling of rates instead of counts. The offset indexes the opportunity for an event to have occurred. For example, a researcher may want to investigate the number of events per unit time, but some study units were observed for a week and others for a month, thus it is expected that there will have been more events for the latter units. This can be accounted for by including an offset variable that indexes the length of time each unit was observed. For example, below is a Poisson regression that has been adapted with an offset to model rates:
$$ \ln\bigg(\frac{{\rm count}}{{\rm time}}\bigg) = \beta_0 + \beta_1X $$ $$ \ln({\rm count})-\ln({\rm time}) = \beta_0 + \beta_1X $$ $$ {\rm count} = {\rm time}\cdot\exp(\beta_0 + \beta_1X) $$ The most common offsets are time and spatial area.

187 questions
90
votes
1 answer

When to use an offset in a Poisson regression?

Does anybody know why offset in a Poisson regression is used? What do you achieve by this?
MarkDollar
  • 5,575
  • 14
  • 44
  • 60
28
votes
2 answers

Where does the offset go in Poisson/negative binomial regression?

(First of all, just to confirm, an offset variable functions basically the same way in Poisson and negative binomial regression, right?) Reading about the use of an offset variable, it seems to me that most sources recommend including that variable…
24
votes
2 answers

In a Poisson model, what is the difference between using time as a covariate or an offset?

I recently discovered how to model exposures over time using the log of (e.g.) time as an offset in a Poisson regression. I understood that the offset corresponds to having time as covariate with coefficient 1. I'd like to better understand the…
Bakaburg
  • 2,293
  • 3
  • 21
  • 30
22
votes
4 answers

Using offset in binomial model to account for increased numbers of patients

Two related questions from me. I have a data frame which contains numbers of patients in one column (range 10 - 17 patients) and 0s and 1s showing whether an incident happened that day. I'm using a binomial model to regress probability of incident…
Chris Beeley
  • 5,465
  • 5
  • 36
  • 40
16
votes
3 answers

Using glm() as substitute for simple chi square test

I am interested in changing the null hypotheses using glm() in R. For example: x = rbinom(100, 1, .7) summary(glm(x ~ 1, family = "binomial")) tests the hypothesis that $p = 0.5$. What if I want to change the null to $p$ = some arbitrary value,…
14
votes
2 answers

Binary Models (Probit and Logit) with a Logarithmic Offset

Does anyone have a derivation of how an offset works in binary models like probit and logit? In my problem, the follow-up window can vary in length. Suppose patients get a prophylactic shot as treatment. The shot happens at different times, so if…
dimitriy
  • 31,081
  • 5
  • 63
  • 138
14
votes
3 answers

Should I use an offset for my Poisson GLM?

I am carrying out research to look at differences in fish density and fish species richness when using two different underwater visual census methods. My data was originally count data but then typically this is changed to fish density but I have…
Vivienne
  • 441
  • 1
  • 4
  • 8
12
votes
1 answer

How to formulate the offset of a GLM

I am trying to build a generalized linear model in R for some count data. Basically I have counted the number of animals per unit after having them presented with a treatment (for all units there was a 6 week exposure). That is, depending on…
Dunen
  • 123
  • 1
  • 1
  • 6
11
votes
2 answers

Can Weights and Offset lead to similar results in poisson regression?

In "A Practioner's guide to Generalized linear models" in paragraph 1.83 it is stated that: "In the particular case of a Poisson multiplicative GLM it can be shown that modelling claim counts with an offset term equal to the log of the exposure…
11
votes
1 answer

Predict GLM poisson with offset

I know this is probably a basic question... But I don't seem to find the answer. I'm fitting a GLM with a Poisson family, and then tried to get a look at the predictions, however the offset does seem to be taken…
Sandra
  • 111
  • 1
  • 1
  • 3
10
votes
3 answers

Modelling count data where offset variable is 0 for some observations

I'm trying to help a student of a colleague. The student observed and counted bird behaviour (number of calls) in an experimental setup. The number of calls attributable to a specific observed bird during each experiment couldn't be determined but…
Gavin Simpson
  • 37,567
  • 5
  • 110
  • 153
8
votes
1 answer

Difference between offset and exposure in Poisson Regression

Exposure and offset are two techniques often used in Poisson regressions by actuaries to predict claim frequency . From my understanding, offset and exposure are the same things, so I don't understand why there are two terms to describe the same…
psql
  • 675
  • 7
  • 13
8
votes
1 answer

How is a Poisson rate regression equal to a Poisson regression with corresponding offset term?

I do not understand the role of weights in "weighted Poisson regression". What exactly is being weighted? Is it the contribution of the observation to the log-likelihood of the model, or something else? In the following two popular threads, Where…
Alex
  • 3,728
  • 3
  • 25
  • 46
8
votes
2 answers

Poisson xgboost with exposure

I was trying to model a count dependent variable with uneven exposure. Classical glms would use log(exposure) as offset, also gbm does, but xgboost does not allow for offset until now... Trying to find a drawback this example in crossvalidated…
Giorgio Spedicato
  • 3,444
  • 4
  • 29
  • 39
8
votes
2 answers

How can Poisson GLM work with non-count data (rate data)?

My question is related, but not the same as the following question: Fitting a Poisson GLM in R - issues with rates vs. counts Here's some fake data: ### some fake data x=c(1:14) y=c(0, 1, 2, 3, 1, 4, 9, 18, 23, 31, 20, 25, 37, 45) y_rate <- y…
1
2 3
12 13