map.statistic: Mapping of a spatial index

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/feedback.spatial.R

Description

Mapping of a spatial index with circles whose sizes and colors vary with the values of the index

Usage

1
2
map.statistic(coordinates, statistic, region, cex.circles = c(3, 0.2), legend, 
	main = NULL, add = FALSE)

Arguments

coordinates

a 2-column matrix with latitudes and longitudes of observation sites.

statistic

a numeric vector specifying the values, at observation sites, of the index to be mapped.

region

a list of arguments defining the region over which the index is mapped:

border:

a character string that names the region in the world within which the statistic will be predicted. This is a character string in the database world; see the function map in the maps package.

xlim:

a numeric vector of size 2 specifying the limits in longitude of the plot. May not be provided.

ylim:

a numeric vector of size 2 specifying the limits in latitude of the plot. May not be provided.

cex.circles

a numeric vector specifying the circle expansion.

legend

a list of arguments defining the location of the legend in the plot:

x:

a numeric vector specifying the longitudes where the legend circles are drawn.

y:

a numeric vector specifying the latitudes where the legend circles are drawn.

xtext:

a numeric vector specifying the longitudes where the values corresponding to the sizes of the legend circles are drawn.

ytext:

a numeric vector specifying the latitudes where the values corresponding to the sizes of the legend circles are drawn.

digits:

integer indicating the number of decimal places to be used.

main

a character string providing an overall title for the plot.

add

a logical indicating whteher the plot must be added to a current plot (if add = TRUE) or not (if add = FALSE), default is FALSE.

Value

a plot.

Author(s)

Samuel Soubeyrand Samuel.Soubeyrand@avignon.inra.fr, Cindy E. Morris, E. Keith Bigg.

References

Soubeyrand, S., Morris, C. E. and Bigg, E. K. (2014). Analysis of fragmented time directionality in time series to elucidate feedbacks in climate data. Environmental Modelling and Software 61: 78-86.

See Also

map.statistic rain.feedback.stats.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
#### load data of feedback and change-in-feedback indices in 88 sites across Australia
data(rain.feedback.stats)

#### spatial coordinates of the 88 sites and corresponding feedback index 
#### computed from the whole data series
coord=rain.feedback.stats[,3:4]
stat1=rain.feedback.stats[["Feedback.whole.period"]]

#### map of feedback index 
map.statistic(coord,stat1,cex.circles=c(3,0.2),
   region=list(border="Australia",xlim=c(110,155)),
   legend=list(x=c(rep(114,3),rep(123,2)),y=-c(37,39.5,42,37,39.5),
      xtext=c(rep(114,3),rep(123,2))+1,ytext=-c(37,39.5,42,37,39.5),digits=2),
   main="Feedback")

FeedbackTS documentation built on Jan. 23, 2020, 5:06 p.m.