Example debugging mixed Python C++ in VS Code

Visual Studio Code has the ability to debug mixed Python with C++ extensions. In this blog post, I give an example of how to get it working. I’m going to do the example from scratch in five steps: Make virtual environment. Chances are that, if you’re doing this kind of thing, you’ll be wanting to use a virtual environment too. Write code. My toy example … Continue reading Example debugging mixed Python C++ in VS Code

Extinction of undiscovered butterflies

Meryl Theng just had a new paper published in Biological Conservation, where she estimated that 46% of Singapore’s butterfly species have been extirpated since 1854. The special thing about this estimate is that it includes all species that existed, including species that went extinct before we had a chance to discover them. The trick to estimating undiscovered extinctions is the SEUX model. There is a … Continue reading Extinction of undiscovered butterflies

New solutions for Parker sperm competition model

Parker et al. (2013) created a general model for sperm allocation under a trade-off between male investment of resources $$R$$ into pre-copulatory effort (e.g. search time) $$T$$ versus post-copulatory effort (e.g. ejaculate) $$U$$. Their model is interesting because it encompasses a range of different scenarios of female remating and the type of competition between males. For female remating scenarios, the risk model has females mating … Continue reading New solutions for Parker sperm competition model

Playing with a new model for fugitive coexistence

I recently read a paper by Kawecki (2017), which presents a new mechanism for something analogous to fugitive coexistence. The paper has a really great literature overview, which I won’t be able to do justice here. In short, fugitive coexistence is when an inferior species persists on a patchy landscape by being a better coloniser: when a local extinction occurs, they are quicker to arrive … Continue reading Playing with a new model for fugitive coexistence

Typo in qualitative modelling paper

There is a typo in our recent paper to MEE, Dealing with high uncertainty in qualitative network models using Boolean analysis. Example 2 of Box 1 should read “y = water/wine” not “y = wine/water”. Many thanks to Anubhav Gupta at University of Zurich for emailing us to let us know. Continue reading Typo in qualitative modelling paper

Pretty diagram of directory structure

In a recent project, I wanted to create a diagram of a repository for the appendix of a paper, including comments to highlight key files and explain how the folders were organised. I found this answer on Stack Exchange by user Gonzalo Medina, which I tweaked to produce the diagram below. The code is below: Continue reading Pretty diagram of directory structure

Why does it matter to conservation decision-making if alternative Qualitative Modelling methods produce contradictory predictions?

Previously, I have written about how the probabilistic approach to Qualitative Modelling (QM) (e.g. Raymond et al. 2011) can lead to contradictory predictions of species response to a management intervention, and how this is similar to the paradoxes of the Principle of Indifference that we find in the philosophy literature. A reviewer of our new manuscript (Kristensen et al. 2019) asked us an interesting and … Continue reading Why does it matter to conservation decision-making if alternative Qualitative Modelling methods produce contradictory predictions?

Fixation probability of birth-death process

The goal is to understand where Eq. 2 of the Supplementary section of Sigmund et al. (2010) came from. We are considering a finite population within which individuals are pursuing different game-theoretic strategies. At each timestep, a pair of individuals is chosen at random, and they engage in a social learning process, where individual $$i$$ will adopt the strategy of individual $$j$$ according … Continue reading Fixation probability of birth-death process

Two new papers about blue tits on Corsica

I recently read two new papers about blue tits in Corsica: Dubuc-Messier et al. (2017 Behav. Ecol.), and Dubuc-Messier et al. (2018 Evol. Biol.). The 2018 paper was interested in whether the differences between the evergreen and deciduous ecotypes on Corsica were genetic or a plastic response to the different habitat types. They took 7-12 day old nestlings and raised them in a common garden, … Continue reading Two new papers about blue tits on Corsica