I have a dataset consisting of latitude-longitude pairs associated with some Z value (eg data regarding degree of plant vegetation coverage).
I'd like to perform some analyses on the spatial distribution of this data.
To do so, it will be necessary to bin proximal data points.
I would like to do this with a Discrete Global Grid such as an Icosahedron Snyder Equal Area (ISEA) grid, or the grid produced by DGGRID .
The key is that the latitude-longitude values of the data can be convertable into unique cell ids, that the latitude-longitude of the cell's center be determinable, the size of the cells be variable (for analysis at different spatial scales), and that the cells be of equal area to a close approximation.
An image depicting how this might look:
Is there anything in R which does this?
After searching high and low for exactly the same issue, I have ended up using DGGRID itself and R. DGGRID is excellent by the way. All the hard work has been done. It would be a major boon to the R community to have it implemented as a package (I hope Kevin Sahr is reading this).
Incidentally, that URL is out of date. I made the same mistake and ended up with an older version of DGGRID. The newest one, which is two versions further along, is at:
I've just completed an R package called dggridR which wraps dggrid in an easy-to-use way.
The package is also available on CRAN .
Why not use DGGRID itself, which can do everything you asked? For example, you could use DGGRID to transform a text file of lat/lon/datavalue records into records of the form cellID/datavalue, and then import those into R.
There is only one other lead I ever turned up for hexagonal gridding over a curved surface: some untested/beta functions for the hexbin package:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.