gkg: Google Knowledge Graph

Description Usage Arguments

View source: R/core.R

Description

Call the Google Knowledge Graph API.

Usage

1
2
gkg(q, limit = 1L, languages = NULL, types = NULL, prefix = NULL,
  key = Sys.getenv("GKG_API_KEY"))

Arguments

q

The search query.

limit

The maximum number of results to retrieve.

languages

The list of language codes (defined in ISO 639) to run the query with, for instance en.

types

Restricts returned entities to those of the specified types. For example, you can specify Person (as defined in http://schema.org/Person) to restrict the results to entities representing people. If multiple types are specified, returned entities will contain one or more of these types.

prefix

Enables prefix (initial substring) match against names and aliases of entities. For example, a prefix Jung will match entities and aliases such as Jung, Jungle, and Jung-ho Kang.

key

Your API key, defaults to looking for the GKG_API_KEY environment variable.


JohnCoene/gkg documentation built on Oct. 30, 2019, 7:56 p.m.