corpora_best_match: Returns a tibble of distances from the reference document for...

Description Usage Arguments Value Examples

View source: R/coRPysprofiling.R

Description

Returns a tibble of distances from the reference document for each corpus in a vector of corpora. This tibble is sorted in the order of increasing distance.

Usage

1
2
3
4
5
6
corpora_best_match(
  refDoc,
  corpora,
  metric = "cosine_similarity",
  model_name = "cb_ns_500_10"
)

Arguments

refDoc

character vector for reference document

corpora

character vector for corpora

metric

character vector for metric used to calculate distance, optional (default : "cosine_similarity")

model_name

character vector, optional (default : "cb_ns_500_10")

Value

tibble

Examples

1
coRPysprofiling::corpora_best_match("kitten meows", c("ice cream is yummy", "cat meowed", "dog barks", "The Hitchhiker's Guide to the Galaxy has become an international multi-media phenomenon"))

UBC-MDS/coRPysprofiling-R documentation built on March 30, 2021, 12:02 p.m.