Skip to content

oOp995/trends

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

trends

Simple trend detection for Rust.

Compare two ordered values and classify the result as:

  • Trend::Rising
  • Trend::Falling
  • Trend::Stable

Example

use trends::TrendExt;

let trend = 10.to_trend(&20);

assert!(trend.is_rising());
assert_eq!(trend.direction(), 1);

Works with any T: Ord.

Explore

About

Simple trend detection for Rust.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages