Learn R Programming

TextForecast (version 0.1.3)

tf_idf: tf-idf function

Description

tf-idf function

Usage

tf_idf(x)

Arguments

x

a input matrix x of terms counting.

Value

a list with the terms tf-idf and the terms tf-idf in descending order.

Examples

Run this code
# NOT RUN {
data("news_data")
X=as.matrix(news_data[,2:ncol(news_data)])
tf_idf_terms = tf_idf(X)
# }

Run the code above in your browser using DataLab