lintul2 {Rlintul}R Documentation

LINTUL2 crop growth model

Description

LINTUL is a relatively simple crop growth simulation model

Usage

lintul2(crop, soil, control, weather)
lintul2_crop()
lintul2_soil()
## S4 replacement method for signature 'Rcpp_Lintul2Model'
crop(x)<-value
## S4 replacement method for signature 'Rcpp_Lintul2Model'
soil(x)<-value
## S4 replacement method for signature 'Rcpp_Lintul2Model'
control(x)<-value
## S4 replacement method for signature 'Rcpp_Lintul2Model'
weather(x)<-value
## S4 method for signature 'Rcpp_Lintul2Model'
run(x, ...)

Arguments

x

Rcpp_Lintul2Model object

crop

list with named crop parameters. See Details. An example is returned by lintul2_crop()

soil

list with named soil parameters. See Details. An example is returned by lintul2_soil()

control

list with named control parameters

weather

data.frame with daily weather data

value

a list with crop, soil, or control parameters, or a data.frame with weather data. As above

...

additional arguments. None implemented

Value

matrix

References

Spitters, C.J.T. and A.H.C.M. Schapendonk, 1990. Evaluation of breeding strategies for drought tolerance in potato by means of crop growth simulation. Plant and Soil 123: 193-203.

Examples


library(Rlintul)
m <- lintul2()
emerg <- as.Date('2012-04-01')
contr <- list(emergence=emerg, start=emerg-1, maxdur=200)
w <- example_weather()
acrop <- lintul2_crop()
asoil <- lintul2_soil()

crop(m) <- acrop
soil(m) <- asoil
control(m) <- contr
weather(m) <- w

m$run()

m$out

# or do 

m2 <- lintul2(acrop, asoil, contr, w)
r <- run(m2)
tail(r)


# Compare with FORTRAN version results)

f1 <- system.file("lintul/test/2/res.dat", package="Rlintul")
s <- readLIN1output(f1)
f2 <- system.file("extdata/Netherlands_Wageningen.csv", package="meteor")
wth <- read.csv(f2)
wth$date <- as.Date(wth$date)
wth$srad <- wth$srad / 1000

m <- lintul2()
crop(m) <- lintul2_crop()
soil(m) <- lintul2_soil()
sdate <- dateFromDoy(58, 1971)
control(m) <- list(emergence=sdate+2, start = sdate, maxdur=365)
weather(m) <- wth
m$run()

x <- m$out

plot(s[,'TIME'], s[,'LAI'], type='l')
points(m$out$step+58, m$out$LAI)

plot(s[,'TIME'], s[,'WSO'], type='l')
points(m$out$step+58, m$out$WSO)


[Package Rlintul version 0.1-4 Index]