glottoget: Get glottodata from local path or online global databases

View source: R/glottoget.R

glottogetR Documentation

Get glottodata from local path or online global databases

Description

Load locally stored glottodata, download databases from online sources, or load built-in demo data

Usage

glottoget(
  glottodata = NULL,
  meta = FALSE,
  download = FALSE,
  dirpath = NULL,
  url = NULL,
  seed = NULL
)

Arguments

glottodata

options are:

  • A filepath to locally stored glottodata or glottosubdata with file extension (.xlsx .xls .gpkg .shp). See also: options meta and simplify.

  • "glottobase" - Default option, an spatially enhanced version of glottolog. See glottobooster for details. If glottodata = NULL, "glottobase" will be loaded.

  • "wals" - This is a spatially enhanced version of WALS.

  • "dplace" - This is a spatially enhanced version of D-PLACE.

  • "glottolog" - This is a restructured (non-spatial) version of glottolog.

  • "glottospace" - A simple dataset with glottocodes and a geometry column. This is a subset of all languages in glottolog with spatial coordinates.

  • "grambank" - This is a restructured (non-spatial) version of Grambank.

  • "grambankspace" - This is a restructured (spatially enhanced) version of Grambank.

  • "phoible_raw" - This is a restructured (non-spatial) raw version of PHOIBLE.

  • "phoiblespace_raw" - This is a restructured (spatially enhanced) raw version of PHOIBLE.

  • "phoible" - This is a restructured (non-spatial) randomly sampled version of PHOIBLE. When seed is not provided, it will randomly choose a sample for each duplicated glottocode.

  • "phoiblespace" - This is a (spatially enhanced) randomly sampled version of PHOIBLE. When seed is not provided, it will randomly choose a sample for each duplicated glottocode.

  • "phoible_raw_param_sf" - This returns an sf object of the geographical distribution for all parameter IDs with respect to the raw PHOIBLE.

  • "phoible_param_sf" - This returns an sf object of the geographical distribution for all parameter IDs with respect to a sampled version of PHOIBLE. When seed is not provided, it will randomly choose a sample for each duplicated glottocode.

  • "demodata" - Built-in artificial glottodata (included for demonstration and testing).

  • "demosubdata" - Built-in artificial glottosubdata (included for demonstration and testing)

  • "demosubdata_cnstn" - Built-in artificial glottosubdata (included for demonstration and testing)

meta

In case 'glottodata' is demodata/demosubdata: by default, meta sheets are not loaded. Use meta=TRUE if you want to include them.

download

By default internally stored versions of global databases are used. Specify download = TRUE in case you want to download the latest version from a remote server.

dirpath

Optional, if you want to store a global CLDF dataset in a specific directory, or load it from a specific directory.

url

Zenodo url, something like this: "https://zenodo.org/api/records/3260727"

seed

the seed number when glottoget phoible dataset, if not provided, the glottoget function will randomly choose one language for each duplicated glottocode.

Value

A glottodata or glottosubdata object (a data.frame or list, depending on which glottodata is requested)

See Also

Other <glottodata>: glottosave()

Examples


glottoget("glottolog")


SietzeN/glottospace documentation built on June 15, 2024, 10:45 p.m.