TEXTMINING: Text mining

TEXTMININGR Documentation

Text mining

Description

Apply data mining function on vectorized text

Usage

TEXTMINING(corpus, miningmethod, vector = c("docs", "words"), ...)

Arguments

corpus

The corpus.

miningmethod

The data mining method.

vector

Indicates the type of vectorization, documents (TF-IDF) or words (GloVe).

...

Parameters passed to the vectorisation and to the data mining method.

Value

The result of the data mining method.

See Also

predict.textmining, textmining-class, vectorize.docs, vectorize.words

Examples

## Not run: 
require (text2vec)
data ("movie_review")
d = movie_review [, 2:3]
d [, 1] = factor (d [, 1])
d = splitdata (d, 1)
model = TEXTMINING (d$train.x, NB, labels = d$train.y, mincount = 50)
pred = predict (model, d$test.x)
evaluation (pred, d$test.y)
text = loadtext ("http://mattmahoney.net/dc/text8.zip")
clusters = TEXTMINING (text, HCA, vector = "words", k = 9, maxwords = 100)
plotclus (clusters$res, text, type = "tree", labels = TRUE)

## End(Not run)

fdm2id documentation built on July 9, 2023, 6:05 p.m.

Related to TEXTMINING in fdm2id...