Hello everyone,
I am using brms to fit an animal model in order to estimate genetic variance of behavioral traits in different populations of stickleback fish. The data consists of time-to-event measurements, where each individual was scored for a behaviour (latency to emerge from a shelter) during a fixed time period of 300 seconds. Each individual in the dataset was given a value in seconds if it expressed the behavior (emerged from the shelter) or a value of 300 if it did not express the behavior. The data is therefore right-censored and also, strongly bimodal (most fish either expressed the behavior early on, or, did not express it at all).
My goal is to estimate genetic variance for this trait by appending the genetic relationship among these individuals (contained in a Genomic Relationship Matrix [GRM]) to the random effect of the model.
My model is specified as follows (and see below for definition of terms):
model <- brm(latency.cen | cens(latency.up) ~ (1|gr(animal,cov=A)),
data = data,
family = "weibull",
data2=list(A=GRM),
chains = 1,
cores = 4,
warmup = 100000,
thin = 1000,
iter = 1100000)
Where, âlatency.cenâ corresponds to the column of original values (time in seconds), âlatency.upâ is the column indicating whether the value is censored (i.e. ârightâ for values = 300) or not (i.e ânoneâ for values != 300), âanimalâ is the column of individual IDs and âGRMâ is the n x n matrix of genetic relatedness where ânâ is the number of individuals.
From this, I have two questions:
1/ As I am new to brms, I wonder if my model syntax is sensible for this purpose?
2/ I used the command: as_draws_df(model) to get a data frame of the model output. I can see that posterior distributions of the random effect are stored for each individual. Is this similar to the output produced by the option âpr = TRUEâ in MCMCglmm ? If so, can these values be thought as breeding values or BLUPs? (as the model includes genetic relationship among individuals)
Thank you very much in advance for your answers, hope my message is clear enough.
Antoine
- Operating System: Windows 10
- brms Version: 2.16.1
- R Version: 4.1.1