glottosave {glottospace}R Documentation

Save glottodata, maps and plots

Description

If no filename is provided, the name of the glottodata object will be used.

Usage

glottosave(glottodata, filename = NULL)

Arguments

glottodata

User-provided glottodata

filename

Filename either with or without file extension

Details

If no file extension is provided, a sensible default file extension is chosen. Dynamic maps (tmap) are saved in .html format, static maps (tmap) are saved as .png. Spatial data (sf) are saved as geopackage (.GPKG) by default, but .shp is also possible.

Value

No object is returned, it will be save locally at the specified location

See Also

glottoget_glottodata

Other <glottodata>: glottoget()

Examples


glottodata <- glottoget("demodata", meta = FALSE)
# Saves as .xlsx
glottosave(glottodata, filename = file.path(tempdir(), "glottodata") )

glottospacedata <- glottospace(glottodata)
# Saves as .GPKG
glottosave(glottodata, filename = file.path(tempdir(), "glottodata") )

glottomap <- glottomap(glottodata)
# Saves as .png
glottosave(glottomap, filename = file.path(tempdir(), "glottomap") )

# Saves as .html
glottomap <- glottomap(glottodata, type = "dynamic",
             filename = file.path(tempdir(), "glottomap") )


[Package glottospace version 0.0.112 Index]