Tf

Trait Tf 

Source
pub trait Tf<T>
where T: NaiveDocument,
{ // Required method fn tf<K>(term: K, doc: &T) -> f64 where K: Borrow<T::Term>; }
Expand description

A strategy to calculate a weighted or unweighted term frequency (tf) score of a term from a document.

Required Methods§

Source

fn tf<K>(term: K, doc: &T) -> f64
where K: Borrow<T::Term>,

Returns the weighted or unweighted term frequency (tf) for a single term within a document.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<T> Tf<T> for BinaryTf
where T: NaiveDocument,

Source§

impl<T> Tf<T> for LogNormalizationTf

Source§

impl<T> Tf<T> for RawFrequencyTf

Source§

impl<T, S> Tf<T> for S