Expand description
Find relationships in a series of location assuming [A,B,A]
implies A->B->A
and A,B
are of
type Point
.
Simple lib to find outliers or path taken less or more frequently than others.
We store location in form of Point(x: f64, y: f64)
, they are automatically rounded off to 3 decimal places when using
new
method on Point
. We assume x,y
are latitude and longitude
and don’t need more than
3 decimal places of precision.
Relevant xkcd
Usage:
use coordinates_outliers::{Point, PointPlane};
let a = Point::new(0.123, 0.123);
let b = Point::new(1.123, 1.123);
let c = Point::new(2.123, 2.123);
let d = Point::new(3.123, 3.123);
let e = Point::new(0.123, 0.123);
let f = Point::new(1.123, 1.123);
let points = vec![a, b, c, d, e, f];
let k = PointPlane::new(points, 100);
println!("{:#?}", k);
Re-exports§
pub use connection::Connection;
pub use graph::Graph;
pub use point::Point;
pub use pointplane::PointPlane;
Modules§
- We represent a directed edge
A->B
, we use the coordinates to compute the hashes but not the weight, with weight being the number of times that path is taken - We are making a directed graph of type
A->B
, it updates the edges if it already exists - A simple point in 2D plane of type (x,y)
- Our main entry point into the library. Maintains the frequency of points, edges, X and Y axis stats and capacity