jiebaR (version 0.10.99)

get_idf: generate IDF dict

Description

Generate IDF dict from a list of documents.

Usage

get_idf(x, stop_word = STOPPATH, path = NULL)

Arguments

x

a list of character

stop_word

stopword path

path

output path

Value

a data.frame or a file

Details

Input list contains multiple character vectors with words, and each vector represents a document.

Stop words will be removed from the result.

If path is not NULL, it will write the result to the path.

See Also

https://en.wikipedia.org/wiki/Tf-idf#Inverse_document_frequency_2

Examples

Run this code
# NOT RUN {
get_idf(list(c("abc","def"),c("abc"," ")))
# }

Run the code above in your browser using DataCamp Workspace