5  Simulation Exercise: Exploring neutral model behavior

5.1 Key questions

  1. How do we systematically explore parameter space for a process model?
  2. How do the outcomes of UNTB simulations change over wide ranges of parameter space?

5.2 Lesson objectives

  1. Write code to explore parameter space for UNTB.
  2. Visualize and interpret plots of outcomes (Hill numbers) for exploratory neutral simulations.

5.3 Lesson outline

Slides

5.3.1 (Coding exercise) Set up the infrastructure to explore ranges of parameters

Or (backup) source the script here

As a group, write a wrapper to run our untb code over ranges of values for M and nu.

Or (backup) source the script here

5.3.2 (Breakout groups) Explore ranges of parameters

5.3.3 (Dicussion) Interpret outcomes

Discussion questions:

  1. Each group describe their outcomes
  2. Did each simulation come out the same?
  3. Do we see unique mapping of M, Nu to Hill numbers? What relationships do we see?
  4. How long did it take to run?

Key points:

  1. Individual simulations come out differently, but the overall behaviors are consistent.
  2. A single outcome variable (e.g. hill0) can come about from multiple combinations of parameters.
  3. Running lots of models as a for loop is slow!