Previous exam review
1. Some basics
- For "equation of sample variance" (see Probability - Important Formulas), do you mean this:
- Observation model for frog counts is Poisson Observation Model? Anything else we need to say?
- In the lecture, we looked at the 2025 exam, which also asked about matrix multiplication:
where and are matrices:
and
So
The relevance of this question is that when you are looking at categorical covariates where some of the possible
2. Terminology
- Estimators is just a number used to estimate some trait of the actual population like sample avergage, sample variance or R2?
- Linear models#Multiple R-squared
- Confidence interval
p-value
If the p-value of a parameter of a linear model (
) is 0.04, it means that this parameter is different from zero with probability 0.04 under the linear model
- This is false, the p-value tells us the probability of us getting a t-value (standardized estimate of distance from zero) at least this extreme under the null model.
- Probability of this value being not equal to zero:
- will be effectively infinite (think of a bell curve)
- Probability of this value being not equal to zero:
Bayesian
True or false: If the Bayesian posterior probability for a parameter of a linear model (e.g.
) is greater than zero is 0.04, it means the parameter is different from zero with probability 0.04
If our posterior probability
Confidence intervals
- the confidence intervals for
interval="confidence"are narrower thaninterval="prediction", see Linear models#Confidence intervals and predictions
3. Linear Modeling
The point of this question is about being able to read and interpret R code. It will be using one of the examples from the weekly exercises. You should be fine with these if you understood the exercises (the 2025 example was with the seal data)
Does the model fit the data accurately?
- If the model looks to fit reasonably well, you can just say it looks good, no serious deviations and describe why
- Remember that no model is perfect. If you say that it is totally bad then you will lose marks.
4. Generalzed linear modeling
Zero-inflation
The first part is asking about ways to deal with zero-inflated data.
- The best answer is to use a Negative-Binomial Observation Model
- You could also use Hurdle Observation Models or a "zero-inflated Poisson" which would work too, but negative-binomial is best
- Reasons for zero-inflated data could be:
- Species tending to cluster in flocks or groups - if you observe one, you will observe many
- It could be a structural problem, like a very rarely occuring species or disease
Joint effects
In the quation that was given, the link function is:
The first thing we should notice is the "lm() command in R.
- We need to use log link to transform the continuous covariate data into the range of Poisson counts
- R command needs to be :
glm(y ~ x * z, family=negative.binomial())- or
glm(y ~ x + z + x*z, family=negative.binomial()) - Or you can use
family=Poisson() - Note that we don't need to know exactly the R commands and it's OK to make mistakes or guess what something is called if you justify it. In reality you could always look it up.
- The model assessment is alright, but there are some indications that it is not great:
- The histogram of residuals is skewed and not perfectly normal
- QQ plot has most values in the upper quantiles outside of the confidence interval
- Residuals vs Predicted shows that there is some underlying structure in the data showing some kind of trend
- The best way to fix this would be to add a random effect into the model. If we do this, then we need to use
glmer()command:glmer(y~ x*z + (1|plot), family=Poisson)
5. Experimental design
Average temperature across Finland
We have data on species count observations and have combined them with average temperature at the sampling sites to make the plot shown here:
!EEB-003_exam_2025, p.7
- As you can see on the plot, we don't have any data from sites below 2 degrees average temperature (e.g. the entire north of Finland)
- Therefore, our pilot data doesn't cover the whole temperature gradient of Finland uniformly.
you have a budget to sample from four additional locations, which temperatures should we sample?
- Obviously we will want to sample sites across the north of Finland with very low temperatures which are not represented in our data now.