class: center, middle, title-slide .title[ # Conclusions ] .date[ ### last updated: 2023-07-01 ] --- class: middle, center ## Take-home messages and recommendations ??? + We'll wrap up the workshop with a few take-home messages + And recommendations for conducting your own analyses. --- ## Make the best of your data with HMMs -- + Here is [a searchable list](applistHMM.html) of HMM analyses of capture-recapture data. ??? + We hope to have provided you with a useful overview of how to use hidden Markov models to analyze capture-recapture data. + We have only scratched the surface of what you can do with these models. + We have assembled a searchable list of HMM analyses of capture-recapture data to get inspiration. -- + This list is not exhaustive, please get in touch with us if you'd like to add a reference. ??? + It is not exhaustive, we'll continue updating it. Feel free to suggest papers to add to the list. --- ## Bayesian capture-recapture analysis with HMMs ??? + Before we leave, we'd like to give you a few pieces of advice. + This is not rocket science. + Just a few things based on our own experience of Bayesian capture-recapture analysis with HMMS. -- + Make your ecological question explicit. ??? + First things first. Make sure you've spent some to time to make your ecological question explicit. + This step will help you to stay on course, and make the right choices. + For example, it's ok to use subsets of your data to address different questions. -- + Think of observations and states first. ??? + Now in terms of modeling. Don't jump on your keyboard right away. + Spend some time thinking about your model with pen and paper. + In particular make sure you have the observations and the states of your HMM. -- + Then write down the observation and transition matrices on paper. ??? + Then write down the transition matrix. You may act as if you had no imperfect detection. This is really what you're after, the ecological process (survival, dispersal, etc). + Proceed with the observation matrix. -- + Start simple, all parameters constant for example. Make sure convergence is reached. ??? + When it comes to model fitting with Nimble, start simple. + Consider all parameters constant. + Make sure convergence is reached. -- + Add complexity one step at a time. ??? + Then add complexity. Time effect for example. Or random effects. + Or uncertainty in the assignment of states. --- ## Bayesian capture-recapture analysis with HMMs -- + Use simulations to better understand your model. + Nimble models can be used to simulate data, check out [this tutorial](https://r-nimble.org/nimbleExamples/simulation_from_model.html). ??? + When it comes to model building, consider simulating data to better understand your model. + You will always learn something on your model by seeing it an engine to generate data, instead of estimating its parameters. + The cool thing with nimble is that you can you models to simulate data. There is a tutorial for that. -- + Do not try to optimize your code. Make it work first, then think of optimization. > ["Premature optimization is the root of all evil"](https://stackify.com/premature-optimization-evil/) - Donald Knuth (creator of TeX and author of ["The Art of Computer Programming"](https://en.wikipedia.org/wiki/The_Art_of_Computer_Programming)) ??? + Another advice, quite general in programming, is to not try to optimize your code + Or to try to make it elegant right away. Make it work first. + Then think of optimization. -- + Read [Bayesian workflow](https://arxiv.org/abs/2011.01808) by Gelman et al. (2021). ??? + More recommendations on Bayesian analyses in this recent paper by Gelman and collaborations. + They offer a workflow for bayesian analyses. + In which they discuss model building, model comparison, model checking, model validation, model understanding and troubleshooting of computational problems. <!-- --- --> <!-- ## Nimble --> <!-- + [TO BE COMPLETED BY ALL] --> <!-- + Go for `nimbleMCMC()` if standard needs. --> <!-- + Unleash full `Nimble` potential for improving MCMC or implementing new distributions. --> --- ## Till next time -- + Website will be updated with your feedbacks + A book is on its way. More in 2024 hopefully.