JavaGrinders.spatial
Class MoveVariable

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by java.util.Vector
              extended by JavaGrinders.Variable
                  extended by JavaGrinders.spatial.CaptureVariable
                      extended by JavaGrinders.spatial.MoveVariable
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, java.util.List, java.util.RandomAccess

public class MoveVariable
extends CaptureVariable

handles a vector of information for a series of moves

See Also:
Serialized Form

Field Summary
 
Fields inherited from class JavaGrinders.spatial.CaptureVariable
latlong
 
Fields inherited from class JavaGrinders.Variable
allData, autoExtracted, df, itsDescriptives, itsHighlitedColor, itsLineColor, itsLocationColor, rand
 
Fields inherited from class java.util.Vector
capacityIncrement, elementCount, elementData
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
MoveVariable(java.lang.String varName, VariableOrganizer theOrganizer)
          Standard constructor for the MovesVariable class using a VariableOrganizer
 
Method Summary
 void asCircularGraph()
          Creates a presenter and plots the movement vectors as a circular graph
 void asSpatialMap()
          Creates a presenter and plots the locations
 void asSpatialMap(boolean xDirection, boolean yDirection)
          Creates a presenter and plots the locations
 Variable cloneSelectedRowsOnly()
          returns a NumberVariable with only the selected rows
 void colorCodeSpeeds()
          lists the speed statistics for the variable using the currently selected set of rows
 MoveDescriptives copyMoveDescriptives()
          fills and returns the Descriptives
 void fill(NumberVariable x, NumberVariable y, NumberVariable z, IntegerVariable time)
          fills the variable with moves starting from 0,0,0.
 void fillDescriptives(java.lang.Double hypVal)
          fills the descriptive statistics for the variable, at the root level only a check for valid data points is performed
 AngleVariable getAngles()
          returns an array of distances for the moves
 NumberVariable getDistances()
          returns an array of distances for the moves
 NumberVariable getDurations()
          returns an array of speeds for the moves
 MoveDescriptives getMoveDescriptives()
          fills and returns the Descriptives
 MoveVector getMoveVector(int row)
          returns the Move stored at a given row of the Vector
 NumberVariable getSpeeds()
          returns an array of speeds for the moves
 java.lang.String getStringValue(int row)
          returns the value from a given row in the array as a String object
 double getTimeSum()
          returns the amount of time covered by the moves
 void listCircularDescriptives()
          lists the speed statistics for the variable using the currently selected set of rows
 void makeNewDescriptives()
          create a new set of descriptives for the variable the object
 CaptureVariable toCapturesVariable()
          returns the Move stored at a given row of the Vector
 
Methods inherited from class JavaGrinders.spatial.CaptureVariable
addMove, applyRandomMoveFromDistribution, asCircularGraph, asSpatialMap, asSpatialSpeedMap, asSpatialSpeedMap, checkConnectedCoords, copySpatialDescriptives, estimateD, fill, fill, fill, fill, fill, fill, fillWithGaussRandom, fillWithRandomFromDistribution, getAnglesFromCenter, getCapture, getCenterLocation, getConnect, getConstraint, getCurrentLocation, getDistanceMatrix, getDistancesToLocation, getEndCapture, getEndTime, getFractalDimension, getFractalDimension, getGroupDescriptives, getHomeRange_MinimumPolygon, getHotellingFResults, getLatLongAsDistances, getMeanDistanceToLocation, getMinNeighborDistance, getMoveDistances, getMoves, getMoves, getNetDisplacement, getNetMove, getNetTime, getSpatialDescriptives, getSpatialVector, getSSCP, getStartCapture, getStartTime, getTimeBetweenFrames, getTimeRefs, getTimes, getTinyStepPath, getXs, getYs, getZs, listCircularDescriptives, listDistanceMatrix, listFractalDimension, listFractalDimension, listGroupDescriptives, listMoveDescriptives, reMapInConstraint, resamplePath, selectAbove, selectAboveDistance, selectAboveEqual, selectAboveSpeed, selectAfter, selectAfterEqual, selectBefore, selectBeforeEqual, selectBelow, selectBelowDistance, selectBelowEqual, selectBelowSpeed, selectBetween, selectInArea, selectXAbove, selectXAboveEqual, selectXBelow, selectXBelowEqual, selectYAbove, selectYAboveEqual, selectYBelow, selectYBelowEqual, selectZAbove, selectZAboveEqual, selectZBelow, selectZBelowEqual, setConnect, setConstraint, setExternalMovesDistribution, setMaxMovingThreshold, setMinMovingThreshold, writeKMLCoords, writeKMLFile, writeKMLFile, writeKMLIntro, writeKMLLine, writeKMLLineStyle, writeKMLOutro, writeKMLPoints
 
Methods inherited from class JavaGrinders.Variable
addValue, append, appendVariable, asJAMAMatrix, asVariableOrganizer, checkMatchingRows, checkMinUseRows, checkNumberIDs, checkSameIDs, checkSameSelectRows, checkSameSelectRows, checkSameUseRows, checkSameUseRows, checkValidRowRange, clone, cloneVariableFrom, combineSelectedWithSavedSelectedRows, copyDescriptives, copySelectStateFrom, customColorSelectedRows, deleteAllRows, deleteDuplicateRows, deleteMissingRows, deleteNonSelectedRows, deleteRow, deleteSelectedRows, deselectAllRows, fill, fill, fill, fill, fill, fill, fillDescriptives, fillIDs, fillWithParser, fillWithParser, fillWithVariable, findFirstValidRow, findLastValidRow, findNextNonMissingRow, findNextValidRow, findNextValue, findPreviousValidRow, getabasedintValue, getAbasedintValue, getArray, getbooleanValue, getcharValue, getCombinedIDs, getCrossTabulation, getCrossTabulation, getCustomColorRow, getDescriptives, getdoubleArray, getdoubleValue, getfloatValue, getFrequencies, getHighliteColor, getHighlitedRow, getIDMap, getIDs, getIDString, getIDStrings, getInteractions, getintValue, getJaccard, getLineColor, getLocationColor, getlongValue, getManhattan, getMissingRow, getName, getNIDs, getNMissingRows, getNotes, getNRows, getNSelectRows, getNUseRows, getNValidRows, getOrganizer, getProximity, getProximity, getRandomValue, getRowOrder, getRowOrderRow, getSelectRow, getSquEuclidian, getStringArray, getTransitions, getUseRow, getValue, getVariableDesignRole, getVariableDesignRoleString, getVariableFormat, getVariableType, highliteSelectedRows, highliteSelectedRows, invalidDescriptives, invertSelectedRows, isAngleType, isContinuousType, isLocationType, isLocked, isNominalType, isOrdinalType, isXVariable, isYVariable, listDescriptives, listDescriptives, listGroupDescriptivesNoDia, listRowOrder, listRows, listRows, listRows, listSelectedRows, listSelectState, listSelectState, listUseRows, makeTableSubSet, matchedIDs, replaceSelectedRows, restoreSelectedRows, restrictToMatchingUseRows, restrictToMatchingUseRows, restrictToValidRowsOnly, reverseRows, saveSelectedRows, selectAllRows, selectDuplicateRows, selectRows, selectUseRows, selectValue, setAnglesType, setCustomColorRow, setFormula, setHighliteColor, setHighlitedRow, setLineColor, setLocationColor, setLocationsType, setLock, setMissingRow, setName, setNominalType, setNotes, setNRows, setOrdinalType, setOrganizer, setRowOrder, setRowOrderRow, setSelectRow, setSelectRows, setSelectRowsToMissing, setValue, setValue, setValue, setValue, setValue, setValue, setVariableDesignRole, setVariableFormat, setVariableType, sort, sort, sort2, updateRowOrder
 
Methods inherited from class java.util.Vector
add, add, addAll, addAll, addElement, capacity, clear, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, toString, trimToSize
 
Methods inherited from class java.util.AbstractList
iterator, listIterator, listIterator
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
iterator, listIterator, listIterator
 

Constructor Detail

MoveVariable

public MoveVariable(java.lang.String varName,
                    VariableOrganizer theOrganizer)
             throws java.lang.Exception
Standard constructor for the MovesVariable class using a VariableOrganizer

Parameters:
varName - assigns a name (String) to the variable
theOrganizer - an instance of VariableOrganizer class coordinates a set of variables with respect to number of data points available and the rows that are currently selected
Throws:
java.lang.Exception
Method Detail

getMoveVector

public MoveVector getMoveVector(int row)
returns the Move stored at a given row of the Vector

Parameters:
row - marks the row in the vector

fill

public void fill(NumberVariable x,
                 NumberVariable y,
                 NumberVariable z,
                 IntegerVariable time)
          throws java.lang.Exception
fills the variable with moves starting from 0,0,0. x, y and z variable from the same row are assumed to belong together

Parameters:
x - the x coordinates
y - the y coordinates
z - the y coordinates, set this to null if the moves are 2D only
time - the time stamp for the capture
Throws:
java.lang.Exception

toCapturesVariable

public CaptureVariable toCapturesVariable()
                                   throws java.lang.Exception
returns the Move stored at a given row of the Vector

Throws:
java.lang.Exception

cloneSelectedRowsOnly

public Variable cloneSelectedRowsOnly()
                               throws java.lang.Exception
returns a NumberVariable with only the selected rows

Overrides:
cloneSelectedRowsOnly in class CaptureVariable
Throws:
java.lang.Exception

getStringValue

public java.lang.String getStringValue(int row)
returns the value from a given row in the array as a String object

Overrides:
getStringValue in class CaptureVariable
Parameters:
row - marks the row in the vector

getDistances

public NumberVariable getDistances()
                            throws java.lang.Exception
returns an array of distances for the moves

Throws:
java.lang.Exception

getAngles

public AngleVariable getAngles()
                        throws java.lang.Exception
returns an array of distances for the moves

Throws:
java.lang.Exception

getSpeeds

public NumberVariable getSpeeds()
                         throws java.lang.Exception
returns an array of speeds for the moves

Overrides:
getSpeeds in class CaptureVariable
Throws:
java.lang.Exception

getDurations

public NumberVariable getDurations()
                            throws java.lang.Exception
returns an array of speeds for the moves

Throws:
java.lang.Exception

getTimeSum

public double getTimeSum()
                  throws java.lang.Exception
returns the amount of time covered by the moves

Throws:
java.lang.Exception

makeNewDescriptives

public void makeNewDescriptives()
create a new set of descriptives for the variable the object

Overrides:
makeNewDescriptives in class CaptureVariable

fillDescriptives

public void fillDescriptives(java.lang.Double hypVal)
                      throws java.lang.Exception
fills the descriptive statistics for the variable, at the root level only a check for valid data points is performed

Overrides:
fillDescriptives in class CaptureVariable
Parameters:
hypVal - the value of the a-priori hypothesis mean
Throws:
java.lang.Exception

getMoveDescriptives

public MoveDescriptives getMoveDescriptives()
                                     throws java.lang.Exception
fills and returns the Descriptives

Throws:
java.lang.Exception

copyMoveDescriptives

public MoveDescriptives copyMoveDescriptives()
                                      throws java.lang.Exception
fills and returns the Descriptives

Throws:
java.lang.Exception

listCircularDescriptives

public void listCircularDescriptives()
                              throws java.lang.Exception
lists the speed statistics for the variable using the currently selected set of rows

Throws:
java.lang.Exception

colorCodeSpeeds

public void colorCodeSpeeds()
                     throws java.lang.Exception
lists the speed statistics for the variable using the currently selected set of rows

Throws:
java.lang.Exception

asSpatialMap

public void asSpatialMap()
Creates a presenter and plots the locations

Overrides:
asSpatialMap in class CaptureVariable

asSpatialMap

public void asSpatialMap(boolean xDirection,
                         boolean yDirection)
Creates a presenter and plots the locations

Overrides:
asSpatialMap in class CaptureVariable
Parameters:
xDirection - do x values increase from left to right?
yDirection - do y values increase from top to bottom?

asCircularGraph

public void asCircularGraph()
Creates a presenter and plots the movement vectors as a circular graph

Overrides:
asCircularGraph in class CaptureVariable