Skip to content

Commit

Permalink
Merge pull request #66 from PoisotLab/next
Browse files Browse the repository at this point in the history
Update documentation
  • Loading branch information
evadelmas authored Mar 4, 2019
2 parents accc80e + b0b2d67 commit bf88478
Show file tree
Hide file tree
Showing 6 changed files with 67 additions and 74 deletions.
5 changes: 4 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ matrix:
julia:
- 0.7
- 1.0
- nightly
addons:
apt:
packages:
Expand All @@ -20,7 +21,9 @@ before_script:
after_success:
- julia -e 'import Pkg; cd(Pkg.dir("BioEnergeticFoodWebs")); Pkg.add("Coverage"); using Coverage; Coveralls.submit(Coveralls.process_folder()); Codecov.submit(Codecov.process_folder())'
- julia -e 'import Pkg; Pkg.add("Documenter")'
- julia -e 'import Pkg; cd(Pkg.dir("BioEnergeticFoodWebs")); include(joinpath("docs", "make.jl"))'
- julia -e 'import Pkg; import Documenter; ENV["DOCUMENTER_DEBUG"] = "true"; import BioEnergeticFoodWebs; include(joinpath("docs", "make.jl"))'
#- julia -e 'using Pkg; ps=Pkg.PackageSpec(name="Documenter", version="0.19"); Pkg.add(ps); Pkg.pin(ps); include(joinpath("docs", "make.jl"))'
#- julia -e 'import Pkg; cd(Pkg.dir("BioEnergeticFoodWebs")); include(joinpath("docs", "make.jl"))'
notifications:
webhooks:
urls:
Expand Down
9 changes: 3 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,26 @@

# Bio-energetic food web model

[![RTD](https://img.shields.io/badge/doc-stable-blue.svg)](https://poisotlab.github.io/BioEnergeticFoodWebs.jl/stable/)
[![RTD](https://img.shields.io/badge/doc-latest-blue.svg)](https://poisotlab.github.io/BioEnergeticFoodWebs.jl/latest/)
[![GitHub tag](https://img.shields.io/github/tag/PoisotLab/BioEnergeticFoodWebs.jl.svg)](https://github.com/PoisotLab/BioEnergeticFoodWebs.jl/releases)
[![DOI](https://zenodo.org/badge/70102258.svg)](https://zenodo.org/badge/latestdoi/70102258)
[![Gitter](https://img.shields.io/gitter/room/PoisotLab/BioEnergeticFoodWebs.jl.svg)](https://gitter.im/PoisotLab/BioEnergeticFoodWebs.jl)

[![BioEnergeticFoodWebs](http://pkg.julialang.org/badges/BioEnergeticFoodWebs_0.4.svg)](http://pkg.julialang.org/?pkg=BioEnergeticFoodWebs)
[![BioEnergeticFoodWebs](http://pkg.julialang.org/badges/BioEnergeticFoodWebs_0.5.svg)](http://pkg.julialang.org/?pkg=BioEnergeticFoodWebs)
[![BioEnergeticFoodWebs](http://pkg.julialang.org/badges/BioEnergeticFoodWebs_0.6.svg)](http://pkg.julialang.org/?pkg=BioEnergeticFoodWebs)

Simulations of biomass flows in food webs is a difficult task, yet performing it
correctly is required to understand the ties betweeen the structure and
function of ecological communities. This package provides a robustly tested,
well-documented, computationally efficient common interface for the simulation
of bio-energetic systems in food webs.

This package is no longer compatible with Julia 0.6 (or older).

## Stable

[![Travis branch](https://img.shields.io/travis/PoisotLab/BioEnergeticFoodWebs.jl/master.svg)](https://travis-ci.org/PoisotLab/BioEnergeticFoodWebs.jl)
[![Coveralls branch](https://img.shields.io/coveralls/PoisotLab/BioEnergeticFoodWebs.jl/master.svg)](https://coveralls.io/github/PoisotLab/BioEnergeticFoodWebs.jl?branch=master)

## In development

[![RTD](https://img.shields.io/badge/doc-latest-blue.svg)](https://poisotlab.github.io/BioEnergeticFoodWebs.jl/latest/)
[![Travis branch](https://img.shields.io/travis/PoisotLab/BioEnergeticFoodWebs.jl/next.svg)](https://travis-ci.org/PoisotLab/BioEnergeticFoodWebs.jl)
[![Coveralls branch](https://img.shields.io/coveralls/PoisotLab/BioEnergeticFoodWebs.jl/next.svg)](https://coveralls.io/github/PoisotLab/BioEnergeticFoodWebs.jl?branch=next)

Expand Down
15 changes: 10 additions & 5 deletions docs/make.jl
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
using Pkg
using Documenter

push!(LOAD_PATH, "../src/")

Pkg.activate(".")
using BioEnergeticFoodWebs

makedocs(
modules = [BioEnergeticFoodWebs]
)
modules = [BioEnergeticFoodWebs],
sitename = "BioEnergeticFoodWebs.jl"
)

deploydocs(
deps = Deps.pip("pygments", "mkdocs", "mkdocs-material", "python-markdown-math"),
julia = "0.6",
repo = "github.com/PoisotLab/BioEnergeticFoodWebs.jl.git"
deps = Deps.pip("pygments", "mkdocs==0.17.5", "mkdocs-material==2.9.4", "python-markdown-math"),
repo = "github.com/PoisotLab/BioEnergeticFoodWebs.jl.git",
devbranch = "next"
)
28 changes: 8 additions & 20 deletions docs/src/man/temperature.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,7 @@ Note that rates can be negative (outside of the thermal range) when using the ex

Bernhardt et al. (2018) proposed an extension of the original model of Eppley (1972). Following this extension the thermal performance curve of rate $q_i$ of species $i$ is defined by the equation:

$$
q_i(T) = M_i^\beta * m0 * exp(b * T) * (1 - (\frac{T - T_{\text{opt}}}{\text{range}/2})^2)
$$
$q_i(T) = M_i^\beta * m0 * exp(b * T) * (1 - (\frac{T - T_{\text{opt}}}{\text{range}/2})^2)$

Where $M_i$ is the body mass of species $i$ and T is the temperature in degrees Kelvin. The default parameters values are described for each rate below.

Expand Down Expand Up @@ -79,9 +77,7 @@ p_newvalues = model_parameters(A, metabolicrate = ExtendedEppley(:metabolicrate,

The Boltzmann Arrhenius model, following the Metabolic Theory in Ecology, describes the scaling of a biological rate ($q$) with temperature by:

$$
q_i(T) = q_0 * M^\beta_i * exp(E-\frac{T_0 - T}{kT_0T})
$$
$q_i(T) = q_0 * M^\beta_i * exp(E-\frac{T_0 - T}{kT_0T})$

Where $q_0$ is the organisms state-dependent scaling coefficient, calculated for 1g at 20 degrees Celsius (273.15 degrees Kelvin), β is the rate specific allometric scaling exponent, $E$ is the activation energy in $eV$ (electronvolts) of the response, $T_0$ is the normalization temperature and $k$ is the Boltzmann constant ($8.617 10^{-5} eV.K^{-1}$). As for all other equations, $T$ is the temperature and $M_i$ is the typical adult body mass of species $i$.

Expand Down Expand Up @@ -190,15 +186,11 @@ p_newvalues = model_parameters(A, handlingtime = ExponentialBA(:handlingtime, pa

To describe a more classical unimodal relationship of biological rates with temperature, one can also use the **extended** Boltzmann Arrhenius function. This is an extension based on the Johnson and Lewin model to describe the decrease in biological rates at higher temperatures (and is still based on chemical reaction kinetics).

$$
q_i(T) = exp(q_0) * M^\beta_i * exp(\frac{E}{kT * l(T)})
$$
$q_i(T) = exp(q_0) * M^\beta_i * exp(\frac{E}{kT * l(T)})$

Where $l(T)$ is :

$$
l(T) = \frac{1}{1 + exp[\frac{-1}{kT} + (\frac{E_D}{T_{opt}} + k * ln(\frac{E}{E_D - E}))]}
$$
$l(T) = \frac{1}{1 + exp[\frac{-1}{kT} + (\frac{E_D}{T_{opt}} + k * ln(\frac{E}{E_D - E}))]}$

#### Growth rate

Expand Down Expand Up @@ -260,8 +252,8 @@ Note: The body-mass allometric scaling (originally defined as $M_i^\beta$) becom

| Parameter | Keyword | Meaning | Default values | References |
| --------- | ---------------------------------- | ------------------------------------ | -------------- | --------------------- |
| $r_0$ | `norm_constant_invertebrate` | growth dependent scaling coefficient | $5.10^13$ | Bideault et al 2019 |
| $r_0$ | `norm_constant_vertebrate` | growth dependent scaling coefficient | $5.10^13$ | Bideault et al 2019 |
| $r_0$ | `norm_constant_invertebrate` | growth dependent scaling coefficient | $5.10^{13}$ | Bideault et al 2019 |
| $r_0$ | `norm_constant_vertebrate` | growth dependent scaling coefficient | $5.10^{13}$ | Bideault et al 2019 |
| $\beta_i$ | `β_producer` | allometric exponent | 0.25 | Gillooly et al., 2002 |
| $\beta_i$ | `β_invertebrate` | allometric exponent | 0.25 | Gillooly et al., 2002 |
| $\beta_i$ | `β_vertebrate` | allometric exponent | 0.25 | Gillooly et al., 2002 |
Expand All @@ -285,9 +277,7 @@ p_newvalues = model_parameters(A, attackrate = ExtendedBA(:attackrate, parameter

A simple gaussian function (or inverted gaussian function depending on the rate) has also been used in studies to model the scaling of biological rates with temperature. This can be formalized by the following equation:

$$
q_i(T) = M_i^\beta * q_{opt} * exp[\pm (\frac{(T - T_{opt})^2}{2s_q^2})]
$$
$q_i(T) = M_i^\beta * q_{opt} * exp[\pm (\frac{(T - T_{opt})^2}{2s_q^2})]$

#### Growth rate

Expand Down Expand Up @@ -412,9 +402,7 @@ If multiple keywords are provided, the model will use this order of priority: bo

To simulate the effect of temperature on body masses, the model uses the following general formula, following Forster and Hirst 2012:

$$
M_i(T) = m_i * exp(log_{10}(PCM / 100 + 1) * T - 293.15)
$$
$M_i(T) = m_i * exp(log_{10}(PCM / 100 + 1) * T - 293.15)$

Where $M_i$ is the body mass of species $i$, $T$ is the temperature (in Kelvins), $m_i$ is the body mass when there is no effect of temperature (provided by the user through `Z`, `bodymass` or `dry_mass_293`) and $PCM$ is the Percentage change in body-mass per degree Celsius. This percentage is calculated differently depending on the type of system or the type of response wanted (Forster and Hirst 2012, Sentis et al 2017):

Expand Down
Loading

0 comments on commit bf88478

Please sign in to comment.