Calculates the Standardised Precipitation (SPI) and Standardised Precipitation-Evapotranspiration (SPEI) indices using NASA POWER data.
The PowerSDI is an R package capable of calculating the SPI and SPEI
using NASA POWER data. The package is based on five R-functions designed
to calculate these two standardised drought indices (SDI) in scientific
and operational/routine modes. The functions ScientSDI()
,
Accuracy()
, Reference()
and,
PlotData()
may be used to assess, among other features, the
ability of the SPI and SPEI frequency distributions to meet the
normality assumption and how well NASA POWER estimates represent
“real-world” data. The OperatSDI()
function calculates both
SPI and SPEI in an operational mode.
The PowerSDI adopts a basic time scale that splits each month into four subperiods: days 1 to 7, days 8 to 14, days 15 to 21, and days 22 to 28, 29, 30, or 31 depending on the month. For instance, if TS=4, the time scale corresponds to a moving window with a 1-month length that is calculated four times each month. If TS=48, the time scale corresponds to a moving window with a 12-month length that is calculated four times each month. This time scale is referred to as “quart.month”.
The package depends on R (>= 3.10) and R packages {nasapower} and {lmom}.
::install_github("gabrielblain/PowerSDI") devtools
Helps the users to verify if the SPI and SPEI calculated from NASA POWER data meet the conceptual assumptions expected from standardised drought indices.
ScientSDI(
lon,
lat,
start.date,
end.date,distr = "GEV",
TS = 4,
Good = "Yes",
sig.level = 0.95,
RainUplim = NULL,
RainLowlim = NULL,
PEUplim = NULL,
PELowlim = NULL
)
NULL
.NULL
.NULL
.A list with data calculated at the time scale selected by the user.
If Good="Yes"
, this list includes:
If Good="No"
, this list includes: * SDI and *
DistPar.
This function also presents other data (in millimetres) calculated from the NASA POWER project:
ScientSDI(
lon = -47.3,
lat = -22.67,
start.date = "1991-01-01",
end.date = "2022-12-31"
)
Verifies how well NASA-POWER data actually represent real-world/observed data.
Accuracy(obs_est, conf.int = "Yes", sig.level = 0.95)
conf.int="Yes"
, confidence intervals are calculated.data("ObsEst")
Accuracy(obs_est = ObsEst, conf.int = "Yes", sig.level = 0.95)
Generates routine operational NASA-SPI and NASA-SPEI estimates in several regions and at distinct time scales.
OperatSDI(
lon,
lat,
start.date,
end.date,PEMethod = "HS",
distr = "GEV",
parms,TS = 4
)
A data frame with:
data("DistPar")
OperatSDI(
lon = -47.3,
lat = -22.67,
start.date = "2023-01-31",
end.date = "2023-07-07",
parms = DistPar
)
Generates scatter plots of rainfall and accumulated potential evapotranspiration.
PlotData(lon, lat, start.date, end.date)
Scatter plots of: * Rainfall and * potential evapotranspiration accumulated at the 1-quart.month time scale.
PlotData(
lon = -47.3,
lat = -22.87,
start.date = "2021-12-28",
end.date = "2022-12-31"
)
Calculates both SPI and SPEI from daily data obtained from a ground weather station or any other reference source.
Reference(ref, distr = "GEV", PEMethod = "HS", TS = 4)
refHS
or refPM
as examples.A data frame with: * Rain, * potential evapotranspiration, * difference between rainfall and potential evapotranspiration, * SPI and SPEI calculated at the time scale selected by the user.
data("refHS")
Reference(ref = refHS, distr = "GEV, PEMethod = "HS", TS = 4)
Contains parameters of the gamma and GEV distributions and the
Pr(Rain=0)
.
DistPar
Generated by the ScientSDI()
function using NASA POWER
data.
data(DistPar)
Contains pairs of reference and estimated data.
ObsEst
Generated by the PowerSDI package using data from the NASA POWER and Agronomic Institute.
data(ObsEst)
Contains data for calculating the SPI and SPEI.
refHS
An 8-column matrix with 10950 rows and 8 variables
Agronomic Institute and NASA POWER
data(refHS)
Contains data for calculating the SPI and SPEI.
refPM
A 11-column matrix with 10958 rows and 11 variables
Agronomic Institute and NASA POWER
data(refPM)
https://github.com/gabrielblain/PowerSDI/issues
MIT
Gabriel Constantino Blain, Graciela da Rocha Sobierajski, Leticia Lopes Martins, and Adam H Sparks Maintainer: Gabriel Constantino Blain, gabriel.blain@sp.gov.br
The package uses data obtained from the NASA Langley Research Center (LaRC) POWER Project funded through the NASA Earth Science/Applied Science Program. The POWER project provides data for support several activities including agriculture and energy. The authors greatly appreciate this initiative.
Allen, R.G.; Pereira, L.S.; Raes, D.; Smith, M. Crop evapotranspiration. In Guidelines for Computing Crop Water Requirements. Irrigation and Drainage Paper 56; FAO: Rome, Italy, 1998; p. 300.
Blain, G. C., 2014. Revisiting the critical values of the Lilliefors test: towards the correct agrometeorological use of the Kolmogorov- Smirnov framework. Bragantia, 73, 192-202. http://dx.doi.org/10.1590/brag.2014.015
Hargreaves, G.H.; Samani, Z.A. 1985.Reference crop evapotranspiration from temperature. Appl. Eng. Agric,1, 96–99.
Mckee, T. B., Doesken, N.J. and Kleist, J., 1993. The relationship of drought frequency and duration to time scales. In: 8th Conference on Applied Climatology. Boston, MA: American Meteorological Society, 179–184.
Stagge, J. H., Tallaksen, L. M., Gudmundsson, L., Van Loon, A. F. and Stahl, K., 2015. Candidate distribution for climatological drought indices (SPI and SPEI). International Journal of Climatology, 35(13), 4027–4040. https://doi.org/10.1002/joc.4267
Package ‘lmom’, Version 2.9, Author J. R. M. Hosking. https://CRAN.R-project.org/package=lmom
Package ‘nasapower’, Version 4.0.10, Author Adam H. Sparks et al., https://CRAN.R-project.org/package=nasapower
Wu, H., Svoboda, M. D., Hayes, M. J., Wilhite, D. A. and Wen, F., 2006. Appropriate application of the standardised precipitation index in arid locations and dry seasons. International Journal of Climatology, 27(1), 65–79. https://doi.org/10.1002/joc.1371.