SScard3: self start for cardinal temperature response

SScard3R Documentation

self start for cardinal temperature response

Description

Self starter for cardinal temperature response function

Usage

card3(x, tb, to, tm)

SScard3(x, tb, to, tm)

Arguments

x

input vector (x) which is normally ‘temperature’.

tb

base temperature

to

optimum temperature

tm

maximum temperature

Details

This function is described in Archontoulis and Miguez (2015) - (doi:10.2134/agronj2012.0506)

Value

card3: vector of the same length as x using a card3 function

Author(s)

Caio dos Santos and Fernando Miguez

Examples


## A temperature response function
require(ggplot2)
set.seed(1234)
x <- 1:50
y <- card3(x, 13, 25, 36) + rnorm(length(x), sd = 0.05)
dat1 <- data.frame(x = x, y = y)
fit1 <- nls(y ~ SScard3(x, tb, to, tm), data = dat1)

ggplot(data = dat1, aes(x, y)) + 
  geom_point() + 
  geom_line(aes(y = fitted(fit1)))


nlraa documentation built on July 9, 2023, 6:08 p.m.