Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 50 lines (30 sloc) 1.97 KB

Travis-CI Build Status Coverage Status CRAN_Status_Badge

rangeMapper is a framework for the study of macroecological patterns of life-history traits.

rangeMapper in a nutshell

  • Datasets (i.e. maps) are retrieved from sqlite project files as objects inheriting from SpatialPixels or data.table. Maps can be plotted directly with plot().
    map = rangeMap.fetch(con, c('median_body_mass', 'median_clutch_size'), spatial = FALSE)
    plot(map, boundary = wrens_boundary, ncol = 2 , outlierDetector = function(x) extremevalues::getOutliersI(x)$limit)

  • The link between the assemblage level (i.e. the raster cell) and the species level (i.e. the data behind the raster cell) is kept explicit at all stages of the project. MAPs are constructed based on SQL aggregate functions or statistical models build in R and can be based on arbitrary subsets defined at both species and assemblage levels.
rangeMap.save(con, FUN = lmSlope, biotab = "life_history_traits",
    biotrait = "body_mass", tableName = "slope_bm_cs",
    formula = log(body_mass) ~ clutch_size,
    subset = list(MAP_species_richness = "SR >= 5",
                  MAP_altitude = "altitude > 1000",
                  BIO_biotab = "Family = 'Troglodytidae'
                                 AND clutch_size is not NULL") )

Installation

devtools::install_github("mpio-be/rangeMapper") # development.
install.packages("rangeMapper") # stable.