| Title: | phenorice |
|---|---|
| Description: | An implementation of phenorice algorithm to detect rice crops from remote sensing data. |
| Authors: | Hongfei Wang [aut], Aniruddha Ghosh [aut], Robert J. Hijmans [cre] |
| Maintainer: | Robert J. Hijmans <[email protected]> |
| License: | GPL (>=2) |
| Version: | 0.1-2 |
| Built: | 2026-10-09 11:59:48 UTC |
| Source: | https://github.com/cropmodels/phenorice |
phenorice model to detect rice from satellite reflectance data
Boschetti, M., L. Busettoa, G. Manfrona, A. Laborte, S. Asilo, S. Pazhanivelan & A Nelson, 2017. PhenoRice: A method for automatic extraction of spatio-temporal information on rice crops using satellite data time series. Remote Sensing of Environment 194: 347-365
Fill missing values (pheno_fill_VI) or fill and smooth (pheno_filter_VI) a vector with time series data
pheno_fill_VI(x, method = "natural") pheno_filter_VI(x)pheno_fill_VI(x, method = "natural") pheno_filter_VI(x)
x |
numeric vector |
method |
character. Passed to |
numeric
Get default parameters for the phenorice model
getPars()getPars()
| Parameters | Explanation | |
evi_meanth |
threshold for annual mean EVI | |
evi_maxth |
threshold for maximum evi | |
evi_minth |
threshold for minimum evi | |
pos_start |
start of heading | |
pos_end |
end of heading | |
vl1 |
the shortest vegetative growth length | |
vl2 |
the longest vegetative growth length | |
winfl |
half period of flooding | |
minndfi |
threshold for ndfi | |
windecr |
period after maximum EVI | |
decr |
percent decrease of EVI after EVI maximum | |
tl1 |
the shortest total growing length | |
tl2 |
the longest total growing length | |
lst_th |
the minmum temperature for planting |
list
p <- getPars() str(p)p <- getPars() str(p)
Find the time-step of a prominent local maximum in a vegetation index time series within a given period.
maxDate(vi, vi_maxth = 0.3, pos_start = 15, pos_end = 40)maxDate(vi, vi_maxth = 0.3, pos_start = 15, pos_end = 40)
vi |
numeric vector with vegetation index values |
vi_maxth |
numeric. Threshold for a valid local maximum after subtracting the series minimum |
pos_start |
integer. First time-step (index) of the search window |
pos_end |
integer. Last time-step (index) of the search window |
The background (minimum) value is subtracted from vi. Local maxima are identified, filtered by vi_maxth and by the window [pos_start, pos_end], and checked for an increase before and decrease after the peak. If more than one candidate remains, the date closest to pos_end is returned.
integer index of the selected maximum, or integer(0) if none is found
evi <- readRDS(system.file("evi.rds", package="phenorice")) evi <- pheno_fill_VI(evi) maxDate(evi)evi <- readRDS(system.file("evi.rds", package="phenorice")) evi <- pheno_fill_VI(evi) maxDate(evi)
Run the phenorice model
phenorice(evi, ndfi, p, lst)phenorice(evi, ndfi, p, lst)
evi |
numeric, rasterstack or SpatRaster with evi values |
ndfi |
numeric, rasterstack or SpatRaster with ndfi values |
p |
list with named parameters based on phenorice method |
lst |
numeric, rasterstack or SpatRaster with lst values |
| Parameters | Explanation | |
evi_meanth |
threshold for annual mean EVI | |
evi_maxth |
threshold for maximum EVI | |
evi_minth |
threshold for minimum EVI | |
pos_start |
start of heading | |
pos_end |
end of heading | |
vl1 |
shortest vegetative growth length | |
vl2 |
longest vegetative growth length | |
winfl |
period for flooding | |
minndfi |
threshold for NDFI | |
windecr |
period after EVI maximum | |
decr |
percent decrease of EVI after EVI maximum | |
tl1 |
shortest total growing length | |
tl2 |
longest total growing length | |
lst_th |
minmum land surface temperature for planting, needs checkLST=TRUE
|
vector
Boschetti, M., L. Busettoa, G. Manfrona, A. Laborte, S. Asilo, S. Pazhanivelan & A Nelson, 2017. PhenoRice: A method for automatic extraction of spatio-temporal information on rice crops using satellite data time series. Remote Sensing of Environment 194: 347-365;
Busetto, L., Zwart, S.J. and Boschetti, M., 2019. Analysing spatial?temporal changes in rice cultivation practices in the Senegal River Valley using MODIS time-series and the PhenoRice algorithm. International Journal of Applied Earth Observation and Geoinformation 75: 15-28.
Wang, H., A. Ghosh, B.A. Linquist, R.J. Hijmans, 2020. Satellite-based observations reveal effects of weather variation on rice phenology. Remote Sensing 12(9):1522
# Get index for one pixel evi <- readRDS(system.file("evi.rds", package="phenorice")) ndfi <- readRDS(system.file("ndfi.rds", package="phenorice")) lst <- readRDS(system.file("lst.rds", package="phenorice")) # Smooth each index evi <- pheno_filter_VI(evi) ndfi <- pheno_fill_VI(ndfi) lst <- pheno_fill_VI(lst) # Get parameters p <- getPars() # Run and get result (planting date, date of max EVI value, flowering date, heading date, harvest date) for tha pixel re <- phenorice(evi, ndfi, p, lst) # Change parameters p['evi_minth'] = .2 re <- phenorice(evi, ndfi, p, lst) f <- system.file("ricevi.rds", package="phenorice") d <- readRDS(f) evi <- unlist(d[1,2:47]) ndfi <- unlist(d[1,48:93]) lst <- unlist(d[1,94:139]) p <- getPars() phenorice(evi, ndfi, p, lst) x <- matrix(NA, 25, 5) for (i in 1:25) { evi <- unlist(d[i,2:47]) ndfi <- unlist(d[i,48:93]) lst <- unlist(d[i,94:139]) x[i,] <- phenorice(evi, ndfi, p, lst) } x# Get index for one pixel evi <- readRDS(system.file("evi.rds", package="phenorice")) ndfi <- readRDS(system.file("ndfi.rds", package="phenorice")) lst <- readRDS(system.file("lst.rds", package="phenorice")) # Smooth each index evi <- pheno_filter_VI(evi) ndfi <- pheno_fill_VI(ndfi) lst <- pheno_fill_VI(lst) # Get parameters p <- getPars() # Run and get result (planting date, date of max EVI value, flowering date, heading date, harvest date) for tha pixel re <- phenorice(evi, ndfi, p, lst) # Change parameters p['evi_minth'] = .2 re <- phenorice(evi, ndfi, p, lst) f <- system.file("ricevi.rds", package="phenorice") d <- readRDS(f) evi <- unlist(d[1,2:47]) ndfi <- unlist(d[1,48:93]) lst <- unlist(d[1,94:139]) p <- getPars() phenorice(evi, ndfi, p, lst) x <- matrix(NA, 25, 5) for (i in 1:25) { evi <- unlist(d[i,2:47]) ndfi <- unlist(d[i,48:93]) lst <- unlist(d[i,94:139]) x[i,] <- phenorice(evi, ndfi, p, lst) } x