public class Centroid extends Object implements Comparable<Centroid>
Constructor and Description |
---|
Centroid(double x) |
Centroid(double x,
int w) |
Centroid(double x,
int id,
boolean record) |
Centroid(double x,
int w,
int id) |
Modifier and Type | Method and Description |
---|---|
void |
add(double x,
int w) |
void |
add(double x,
int w,
Iterable<? extends Double> data) |
int |
compareTo(Centroid o) |
int |
count() |
static Centroid |
createWeighted(double x,
int w,
Iterable<? extends Double> data) |
List<Double> |
data() |
int |
hashCode() |
int |
id() |
void |
insertData(double x) |
double |
mean() |
String |
toString() |
public Centroid(double x)
public Centroid(double x, int w)
public Centroid(double x, int w, int id)
public Centroid(double x, int id, boolean record)
public void add(double x, int w)
public double mean()
public int count()
public int id()
public int compareTo(Centroid o)
compareTo
in interface Comparable<Centroid>
public void insertData(double x)
public static Centroid createWeighted(double x, int w, Iterable<? extends Double> data)
Copyright © 2015. All rights reserved.