Learn R Programming

precintcon (version 2.3.0)

pplot.spi: Plot Standardized Precipitation Index

Description

Plots the Standardized Precipitation Index of a precipitation serie.

Usage

pplot.spi(..., period = 3, distribution = "Gamma", xlab = "Months", ylab = "SPI", ylim = c(-3,3), legend = NULL, fontsize = 10, axis.text.color = "black", export = FALSE, export.name = "spi_plot.png", width = 8.6, height = 7.5, units = "cm")

Arguments

period
the number of months to be aggregated for calculating the standardized precipitation index. (Default value: 3)
distribution
it has no effect yet. (Default value: "Gamma")
xlab
the text for the x axis. (Default value: "Months")
ylab
the text for the y axis. (Default value: "SPI")
ylim
the limits of the y axis. (Default value: c(-3, 3))
legend
the text vector for the legend items. If NULL the legends will be equals to the variable names. (Default value: NULL)
fontsize
the font size value in pt. (Default value: 10)
axis.text.color
the legend colors. (Default value: "black")
export
the logical value for defining whether the graph should be export to a file or not. (Default value: FALSE)
export.name
the text for defining the exported file name. It is only used if export = TRUE. (Default value: "spi_plot.png")
width
the number for defining the exported graph width. It is only used if export = TRUE. (Default value: 8.6)
height
the number for defining the exported graph height. It is only used if export = TRUE. (Default value: 7.5)
units
the text for defining the units of the height and width parameters. It is only used if export = TRUE. (Default value: "cm")
...
a set of daily or monthly precipitation series.

See Also

read.data

Examples

Run this code
##
# Loading the daily precipitation serie.
data(daily)

##
# Performing the a set of statistical analysis
pplot.spi(daily)

Run the code above in your browser using DataLab