Methods for 'dplyr' verbs for 'sp' 'Spatial' classes. The basic verbs that modify data attributes, remove or re-arrange rows are supported and provide complete 'Spatial' analogues of the input data. The group by and summarize work flow returns a non-topological spatial union. There is limited support for joins, with left and inner to copy attributes from another table.
spdplyr provides methods for the
dplyr verbs for the
Spatial classes in the
Install from CRAN:
The development version of
spdplyr can be installed directly from Github:
dplyr verbs to the attribute data of
sp objects with dplyr verbs.
?dplyr-Spatial for supported verbs.
added methods for dplyr::groups and dplyr::tbl_vars as per https://github.com/mdsumner/spdplyr/issues/10, these are dependent on utils::packageVersion("dplyr") > "0.5.0"
fixed a bug from using '[email protected]' within a tibble() call where '.data' has a special meaning
updated tests based on minor changes in dplyr around expected warning contents
fixed problem caused by drop = TRUE https://github.com/mdsumner/spdplyr/pull/13
incorporated PR https://github.com/mdsumner/spdplyr/pull/12 to get data frame from data slot instead of using as.data.frame, and extra tests
updated to use sp rather than spFromTable in line with spbabel
modified the print/show details for Spatial
removed some leftover references from original source
first working version
forked from spbabel 0b95adb3, previous news is from spbabel originally
various improvements provided by jlegewie, removed transmute_ (not needed), improved filter_ and select_, added left_join and inner_join, see https://github.com/mdsumner/spbabel/pull/10
added group_by and complementary summarize capability for Spatial
set data.frame and tbl and tbl_df as S4 compatible