pl_gist: Make an interactive map to view in the browser as a GitHub...

View source: R/pl_gist.R

pl_gistR Documentation

Make an interactive map to view in the browser as a GitHub gist

Description

Make an interactive map to view in the browser as a GitHub gist

Usage

pl_gist(x, file = NULL, description = "", public = TRUE, browse = TRUE, ...)

Arguments

x

Output from pl_places()

file

(character) File name (without file extension) for your geojson file. Default is 'gistmap'.

description

(character) Description for the Github gist, or leave to default (=no description)

public

(logical) Whether gist is public (default: TRUE)

browse

(logical) If TRUE (default) the map opens in your default browser.

...

Curl options, see curl::curl_options()

Details

There are two ways to authorise gistr to work with your GitHub account:

  • Generate a personal access token at https://docs.github.com/en/free-pro-team@latest/github/authenticating-to-github/creating-a-personal-access-token and record in the GITHUB_PAT envar.

  • Interactively login into your GitHub account and authorise with OAuth

Using the GITHUB_PAT option is recommended.

Value

Creates a gist on your GitHub account

Examples

## Not run: 
x <- pl_places(place_id = 462471)
pl_gist(x)

## End(Not run)

ropensci/pleiades documentation built on May 18, 2022, 5:40 p.m.