Learn R Programming

embryogrowth (version 5.0)

MovingIncubation: Simulate incubation of a nest with the beginning of incubation varying

Description

Simulate incubation of a nest with the beginning varying day by day Temperatures must be in a data.frame with one column (Time) being the time and the second the temperatures (Temperatures). Do not use FormatNests() for this dataframe.

Usage

MovingIncubation(result = stop("A result file from searchR() must be provided"),
  temperatures = stop("A timeseries of temperature must be provided"),
  times = stop("A timeseries of time for each temperature must be provided"),
  temperatures.end.incubation = temperatures,
  average.incubation.duration = 60 * 1440, skip = 1, parameters = NULL,
  fixed.parameters = NULL, SE = NULL, derivate = NULL, test = NULL,
  M0 = NULL, TSP.borders = c(21, 26), embryo.stages = "Caretta caretta",
  replicate.CI = 1, min.length = 40 * 1440, max.length = 150 * 1440,
  progress = TRUE)

Arguments

result
A result file generated by searchR
times
Timeseries of times
temperatures
Timeseries of temperatures
temperatures.end.incubation
Timeseries of temperatures at the end of incubation
average.incubation.duration
The average time to complete incubation
skip
Number of data to skip between two runs
min.length
Minimum length of possible incubation
max.length
Maximum length of possible incubation
parameters
A set of parameters if result is not provided.
fixed.parameters
Another set of parameters if result is not provided.
SE
Standard error for each parameter if not present in result is not provided (not used still)
derivate
Function used to fit embryo growth: dydt.Gompertz, dydt.exponential or dydt.linear
test
Mean and SD of size of hatchlings as a vector ie test=c(Mean=xx, SD=yy)
M0
Measure of hatchling size proxi at laying date
TSP.borders
The limits of TSP
embryo.stages
The embryo stages. At least TSP.borders stages must be provided to estimate TSP length
replicate.CI
Number of randomizations to estimate CI (not used still)
progress
If TRUE, progression bar is shown (desactivate for sweave or knitr)

Value

  • A dataframe with informations about thermosensitive period length and incubation length day by day of incubation

Details

MovingIncubation simulate incubation of a nest with the beginning varying day by day

Examples

Run this code
library(embryogrowth)
data(resultNest_4p)
ti <- seq(from=0, to=(60*24*100), by=60)
temp <- rnorm(length(ti), 29, 5)
out <- MovingIncubation(result=resultNest_4p, temperatures=temp,
times=ti)

Run the code above in your browser using DataLab