Learn R Programming

Rwofost (version 0.8-7)

wofost: WOFOST crop growth model

Description

Run the WOFOST crop growth model. Through this interface, you provide weather data, and crop, soil and control parameters to run the model once. For multiple runs it might be preferable to use wofost_model instead.

Usage

wofost(crop, weather, soil, control)

Value

matrix

Arguments

crop

list. Crop parameters

weather

data.frame with weather data

soil

list. Soil parameters

control

list. Model control options

Details

The weather data must be passed as a data.frame with the following variables and units.

variabledescriptionclass / unit
date"Date" class variable-
sradSolar radiationkJ m-2 day-1
tminMinimum temperaturedegrees C
tmaxMaximum temperaturedegrees C
vaprVapor pressurekPa
windWind speedm s-1
precPrecipitationmm day-1

Note that there should not be any time gaps between the days in the data.frame

References

Van Diepen, C.A., J. Wolf, and H van Keulen, 1989. WOFOST: a simulation model of crop production. Soil Use and Management, 5: 16-24

Van Keulen, H. and J. Wolf, 1986. Modelling of agricultural production : weather, soils and crops. https://edepot.wur.nl/168025

See Also

wofost_model

Examples

Run this code

# weather data
f <- system.file("extdata/Netherlands_Swifterbant.csv", package="meteor")
w <- read.csv(f)
w$date <- as.Date(w$date)
head(w)

# crop and soil parameters
crop <- wofost_crop("barley")
soil <- wofost_soil("ec1")

# "control" parameters
contr <- wofost_control()
contr$modelstart <- as.Date("1980-02-06")
contr$latitude=52.57
contr$elevation=50


# run model
d <- wofost(crop, w, soil, contr)

# output
head(d)
tail(d)
plot(d[,"step"], d[, "LAI"])


## Another example
crop <- wofost_crop("rapeseed_1001")
soil <- wofost_soil("soil_5")
contr$modelstart <- as.Date("1977-01-01")

rp <- wofost(crop, w, soil, contr)
plot(rp[,"step"], rp[, "LAI"])

# yield
plot(rp[, 1], rp[,"WSO"])


## water limited
contr$water_limited <- TRUE
contr$modelstart <- as.Date("1985-01-01")

crop <- wofost_crop("maize_1")
f <- system.file("extdata/Philippines_IRRI.csv", package="meteor")
wth <- read.csv(f)
wth$date <- as.Date(wth$date)
contr$elevation <- 21
contr$latitude <- 14.18

ma <- wofost(crop, wth, soil, contr)
plot(ma[,"step"], ma[, "LAI"])

Run the code above in your browser using DataLab