Skip to content

... know which layers are provided?

This page gives an overview of the methods to get access to additional information about the data available through different data providers. Note that the documentation website has a series of auto-generated pages that summarize the same information.

julia
using SpeciesDistributionToolkit
using InteractiveUtils

Note that when working from the REPL, InteractiveUtils is loaded by default.

Data are identified by a RasterProvider (e.g. the initiative or website providing the data), and a RasterDataset that is a collection of layers representing specific information.

Listing the providers

julia
subtypes(RasterProvider)
6-element Vector{Any}:
 BiodiversityMapping
 CHELSA1
 CHELSA2
 EarthEnv
 PaleoClim
 WorldClim2

Listing the datasets associated to a provider

The provides method from SimpleSDMDatasets will return true if the provide offers the dataset:

julia
[ds for ds in subtypes(RasterDataset) if SimpleSDMDatasets.provides(WorldClim2, ds)]
9-element Vector{DataType}:
 AverageTemperature
 BioClim
 Elevation
 MaximumTemperature
 MinimumTemperature
 Precipitation
 SolarRadiation
 WaterVaporPressure
 WindSpeed

Datasets with multiple layers

The layers and layerdescriptions methods return a list of layers:

julia
SimpleSDMDatasets.layers(RasterData(CHELSA2, BioClim))
19-element Vector{String}:
 "BIO1"
 "BIO2"
 "BIO3"
 "BIO4"
 "BIO5"
 "BIO6"
 "BIO7"
 "BIO8"
 "BIO9"
 "BIO10"
 "BIO11"
 "BIO12"
 "BIO13"
 "BIO14"
 "BIO15"
 "BIO16"
 "BIO17"
 "BIO18"
 "BIO19"
julia
SimpleSDMDatasets.layerdescriptions(RasterData(CHELSA2, BioClim))
Dict{String, String} with 19 entries:
  "BIO8" => "Mean Temperature of Wettest Quarter"
  "BIO14" => "Precipitation of Driest Month"
  "BIO16" => "Precipitation of Wettest Quarter"
  "BIO18" => "Precipitation of Warmest Quarter"
  "BIO19" => "Precipitation of Coldest Quarter"
  "BIO10" => "Mean Temperature of Warmest Quarter"
  "BIO12" => "Annual Precipitation"
  "BIO13" => "Precipitation of Wettest Month"
  "BIO2" => "Mean Diurnal Range (Mean of monthly (max temp - min temp))"
  "BIO11" => "Mean Temperature of Coldest Quarter"
  "BIO6" => "Min Temperature of Coldest Month"
  "BIO4" => "Temperature Seasonality (standard deviation ×100)"
  "BIO17" => "Precipitation of Driest Quarter"
  "BIO7" => "Temperature Annual Range (BIO5-BIO6)"
  "BIO1" => "Annual Mean Temperature"
  "BIO5" => "Max Temperature of Warmest Month"
  "BIO9" => "Mean Temperature of Driest Quarter"
  "BIO3" => "Isothermality (BIO2/BIO7) (×100)"
  "BIO15" => "Precipitation Seasonality (Coefficient of Variation)"
SimpleSDMDatasets.RasterDataset Type
julia
RasterDataset

This is an abstract type to label something as being a dataset. Datasets are given by RasterProviders, and the same dataset can have multiple providers.

source

SimpleSDMDatasets.RasterProvider Type
julia
RasterProvider

This is an abstract type to label something as a provider of RasterDatasets. For example, WorldClim2 and CHELSA2 are RasterProviders.

source