rcorpus {ngram}R Documentation

Random Corpus

Description

Generate a corpus of random "words".

Usage

rcorpus(nwords = 50, alphabet = letters, minwordlen = 1, maxwordlen = 6)

Arguments

nwords

Number of words to generate.

alphabet

The pool of "letters" that word generation coes from. By default, it is the lowercase roman alphabet.

minwordlen, maxwordlen

The min/max length of words in the generated corpus.

Value

A string.

Examples

rcorpus(10)


[Package ngram version 3.2.3 Index]