io.github.mianalysis.mia.process.analysis.DirectionalityRatioCalculator Maven / Gradle / Ivy
package io.github.mianalysis.mia.process.analysis;
import java.util.TreeMap;
/**
* Created by Stephen on 15/04/2017.
*/
public class DirectionalityRatioCalculator implements SpatialCalculator {
public TreeMap calculate(double[] x, double[] y, double[] z, int[] f) {
TreeMap euclideanDistance = new EuclideanDistanceCalculator().calculate(x,y,z,f);
TreeMap totalLength = new CumulativePathLengthCalculator().calculate(x,y,z,f);
TreeMap directionalPersistance = new TreeMap<>();
directionalPersistance.put(f[0],0d);
for (int i=0;i