Exclude NA's in brms

Hello,

So my data included many rows with Na’s. I tried to run the model as is, but it gave the error: "Error: All observations in the data were removed presumably because of NA values.In addition: Warning message:Rows containing NAs were excluded from the model. "
That is, the NA’s are included for a reason, but would like brms to ignore those.
Is there a way to do so?

brms does ignore the NAs exactly as it should. The problem is that there are too many NAs in your data so, in the end, there are no complete rows left. Depending on the level of missingness you could potentially model the missing data:
https://cran.r-project.org/web/packages/brms/vignettes/brms_missings.html

1 Like