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
 MoveDescriptives itsDescriptives
           
 
Fields inherited from class JavaGrinders.spatial.CaptureVariable
rand
 
Fields inherited from class JavaGrinders.Variable
autoExtracted, df, doWarnings, itsHighlitedColor, itsLineColor, itsLocationColor
 
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 fill(NumberVariable x, NumberVariable y, NumberVariable z, IntegerVariable time)
          fills the variable with moves starting from 0,0,0.
 void fillDescriptives()
          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
 MoveVector getNetMove()
          returns the time difference between first and last capture
 double getNetTime()
          returns the time difference between first and last capture
 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 invalidDescriptives()
          an action has changed data, the descriptive stats thus need to be updated
 void listDescriptives()
          lists the descriptive statistics for the variable using the currently selected set of rows
 void listMoveDescriptives()
          lists the descriptive statistics for the variable using the currently selected set of rows
 void listSpeedDescriptives()
          lists the speed statistics for the variable using the currently selected set of rows
 CaptureVariable toCapturesVariable()
          returns the Move stored at a given row of the Vector
 
Methods inherited from class JavaGrinders.spatial.CaptureVariable
addMove, applyRandomMoveFromDistribution, checkConnectedCoords, compareNGroups, estimateD, fill, fill, fill, fill, fill, fillDescriptives, fillWithGaussRandom, fillWithRandomFromDistribution, getAngles, getAnglesFromCenter, getCapture, getCenterLocation, getCircularDescriptives, getConnect, getConstraint, getCurrentLocation, getDistancesToLocation, getEndCapture, getEndTime, getFractalDimension, getFractalDimension, getGroupDescriptives, getHomeRange_MinimumPolygon, getHotellingFResults, getMeanDistanceToLocation, getMinNeighborDistance, getMoveDistances, getMoves, getMoves, getNetDisplacement, getSpatialDescriptives, getSpatialVector, getSSCP, getStartCapture, getStartTime, getTimeBetweenFrames, getTimes, getTinyStepPath, getXs, getYs, getZs, listCircularDescriptives, listDistanceMatrix, listFractalDimension, listFractalDimension, listGroupDescriptives, listSpatialDescriptives, 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, setLocationsType, setMaxMovingThreshold, setMinMovingThreshold
 
Methods inherited from class JavaGrinders.Variable
addValue, asJAMAMatrix, asVariableOrganizer, checkMinUseRows, checkNumberIDs, checkSameIDs, checkSameSelectRows, checkSameSelectRows, checkSameUseRows, checkSameUseRows, checkValidRowRange, combineSelectedWithSavedSelectedRows, copySelectStateFrom, customColorSelectedRows, deleteMissingRows, deleteNonSelectedRows, deleteRow, deleteRows, deleteSelectedRows, deselectAllRows, deselectRows, fill, fill, fill, fill, fill, fillDescriptives, fillWithParser, fillWithParser, fillWithVariable, findFirstValidRow, findLastValidRow, findNextNonMissingRow, findNextValidRow, findPreviousValidRow, getabasedintValue, getAbasedintValue, getbooleanValue, getcharValue, getCombinedIDs, getCrossTabulation, getCrossTabulation, getCustomColorRow, getDescriptives, getdoubleArray, getdoubleValue, getfloatValue, getHighlitedRow, getIDs, getIDString, getIDStrings, getInteractions, getintValue, getJaccard, getlongValue, getManhattan, getMissingRow, getName, getNIDs, getNMissingRows, getNotes, getNRows, getNSelectRows, getNUseRows, getNValidRows, getOrganizer, getProximity, getProximity, getRandomValue, getSelectRow, getSquEuclidian, getStringArray, getTransitions, getUseRow, getValue, getVariableDesignRole, getVariableDesignRoleString, getVariableFormat, getVariableType, highliteSelectedRows, invertSelectedRows, isAngleType, isContinuousType, isLocationType, isLocked, isNominalType, isOrdinalType, isXVariable, isYVariable, listBasics, listFrequencies, listGroupDescriptivesNoDia, listIDs, listRows, listRows, listSelectedRows, listSelectState, listSelectState, listUseRows, matchedIDs, reportWarnings, restoreSelectedRows, restrictToMatchingUseRows, restrictToMatchingUseRows, reverseRows, saveSelectedRows, selectAllRows, selectRows, selectStringValue, selectUseRows, selectValue, setAnglesType, setCustomColorRow, setFormula, setHighliteColor, setHighlitedRow, setLineColor, setLocationColor, setLock, setMissingRow, setName, setNominalType, setNotes, setNRows, setOrdinalType, setOrganizer, setSelectRow, setSelectRowsToMissing, setValue, setValue, setValue, setValue, setValue, setValue, setVariableDesignRole, setVariableFormat, setVariableType, setWarnings, sort
 
Methods inherited from class java.util.Vector
add, add, addAll, addAll, addElement, capacity, clear, clone, 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
 

Field Detail

itsDescriptives

public MoveDescriptives itsDescriptives
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

Overrides:
fill in class CaptureVariable
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

getNetTime

public double getNetTime()
                  throws java.lang.Exception
returns the time difference between first and last capture

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

getNetMove

public MoveVector getNetMove()
                      throws java.lang.Exception
returns the time difference between first and last capture

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

invalidDescriptives

public void invalidDescriptives()
an action has changed data, the descriptive stats thus need to be updated

Overrides:
invalidDescriptives in class CaptureVariable

getMoveDescriptives

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

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

fillDescriptives

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

Throws:
java.lang.Exception

listDescriptives

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

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

listMoveDescriptives

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

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

listSpeedDescriptives

public void listSpeedDescriptives()
                           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