|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.encog.util.arrayutil.WindowDouble
public class WindowDouble
This class implements a simple sliding window. Arrays of doubles can be added to the window. The sliding window will fill up to the specified size. Additional entries will cause the oldest entries to fall off.
Constructor Summary | |
---|---|
WindowDouble(int theSize)
Construct the window. |
Method Summary | |
---|---|
void |
add(double[] a)
Add an array to the window. |
double |
calculateMax(int index,
int starting)
Calculate the max value, for the specified index, over all of the data in the window. |
double |
calculateMin(int index,
int starting)
Calculate the max value, for the specified index, over all of the data in the window. |
void |
clear()
Clear the contents of the window. |
double[] |
getLast()
Get the last value from the window. |
boolean |
isFull()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public WindowDouble(int theSize)
theSize
- The size of the window.Method Detail |
---|
public void add(double[] a)
a
- The array.public void clear()
public boolean isFull()
public double calculateMax(int index, int starting)
index
- The index of the value to compare.starting
- The starting position, inside the window to compare at.
public double calculateMin(int index, int starting)
index
- The index of the value to compare.starting
- The starting position, inside the window to compare at.
public double[] getLast()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |