pol_corpus: Polish search

Description Usage Arguments Author(s) Examples

Description

Post query to the National Corpus of Polish (nkjp.pl). Don't forget to check http://nkjp.pl/poliqarp/help/plse3.html#x4-50003 for advanced query language.

Usage

1
2
pol_corpus(query, tag = F, n_results = 10, corpus = "nkjp300", kwic = T,
  write = F)

Arguments

query

Vector of length 1 which contain query.

tag

Logical. Do you need morphological tags? By default is FALSE.

n_results

Integer. Defines number of examples from the corpus. By default is 10

corpus

Vector with a type of the corpus: "nkjp300", "nkjp1800", "nkjp1M", "ipi250", "ipi030", "frequency-dictionary"

kwic

Logical. KWIC (key word in context) is the format for resulted lines. If TRUE, then it returns a dataframe with query in the middle and left and right contexts. If FALSE, then it returns each result in one string. By default is TRUE.

write

This argument writes a file in the working derictory (see function getwd() and setwd() for more information). If FALSE, then it creates a dataframe in Global Environment. Otherwise function writes a .tsv file with the name frome the argument value. By default is FALSE.

Author(s)

George Moroz <agricolamz@gmail.com>

Examples

1
2
3
4
pol_corpus("boisz się")
pol_corpus("boisz się", tag = TRUE, n_results = 40)
pol_corpus("An*a")
pol_corpus("[base = 'strzyc']")

agricolamz/lingcorpora.R documentation built on May 10, 2019, 7:34 a.m.