related_words: Retrieve related words

Description Usage Arguments Value Examples

View source: R/words.R

Description

related_words grabs terms that are in some way associated with the words argument.

Usage

1
related_words(key, words, use_canonical = FALSE, ...)

Arguments

key

a Wordnik API key. These can be obtained at the Wordnik developer portal.

words

a vector of words.

use_canonical

whether to use the stemmed, canonical form of the word (i.e. 'cat', for 'cats') instead of the actual word. FALSE by default. Note that for pronunciations specifically, setting it to TRUE may get a wider range of pronunciations; you should experiment.

...

further arguments to pass to httr's GET.

Value

a data.frame of 3 columns: word (the original term), type (the type of relationship) and related_word.

Examples

1
2
3
4
## Not run: 
cat_adjacent <- related_words(key = "madeupkey", words = "cat")

## End(Not run)

birdnik documentation built on May 27, 2018, 5:04 p.m.