JavaGrinders.spatial
Class CaptureVariable

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
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, java.util.List, java.util.RandomAccess
Direct Known Subclasses:
Animal, MoveVariable

public class CaptureVariable
extends Variable
implements java.lang.Cloneable

handles a variable of Captures (capture localities and time of capture).

See Also:
Serialized Form

Field Summary
 boolean 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
CaptureVariable(java.lang.String varName, VariableOrganizer theOrganizer)
          Standard constructor for the CaptureVariable class using a VariableOrganizer
 
Method Summary
 void addMove(MoveVector aMove)
          makes the animal move from the last recorded position
 MoveVector applyRandomMoveFromDistribution(Capture StartCapture)
          generates a single move from a Distribution of Moves
 void asCircularGraph()
          Creates a circular presenter
 void asCircularGraph(boolean relative)
          Creates a circular presenter
 void asSpatialMap()
          Creates a presenter and plots and connects the locations
 void asSpatialMap(boolean xDirection, boolean yDirection)
          Creates a presenter and plots the locations
 void asSpatialMap(boolean xDirection, boolean yDirection, int view)
          Creates a presenter and plots the locations
 void asSpatialSpeedMap()
          Creates a presenter and plots and connects the locations
 void asSpatialSpeedMap(boolean xDirection, boolean yDirection)
          Creates a presenter and plots the locations
 boolean checkConnectedCoords()
          assures that coordinates are connected
 Variable cloneSelectedRowsOnly()
          returns a copy of the CaptureVariable contianing only the selected rows
 SpatialDescriptives copySpatialDescriptives()
          fills the descriptive statistics for the variable and returns the results
 double estimateD(double maxPathLength, double stepSize, double pathLength)
          returns the fractal dimension of the coordinates
 void fill(NumberVariable x, NumberVariable y)
          Fills the variable with captures, x and y variable from the same row are assumed to belong together
 void fill(NumberVariable x, NumberVariable y, NumberVariable z, TimeVariable time)
          Fills the variable with captures, x and y variable from the same row are assumed to belong together
 void fill(NumberVariable x, NumberVariable y, TimeVariable time)
          Fills the variable with captures, x and y variable from the same row are assumed to belong together
 void fill(PolarVector[] aVecs)
          fills the variable with captures
 void fill(java.awt.Polygon poly)
          fills the variable with locations from x and y coordinates that mark the corners of a polygon.
 void fill(SpatialVector[] aVecs)
          fills the variable with captures
 void fillDescriptives(java.lang.Double hypVal)
          fills the descriptive statistics for the variable - locations
 void fillWithGaussRandom(Capture StartCapture, double theMean, double theSD, boolean is3D)
          fills the variable with random values from a uniform distribution between 0 and 1
 void fillWithRandomFromDistribution(Capture StartCapture)
          fills the variable with random values from a Distribution of Moves
 NumberVariable getAnglesFromCenter()
          returns the distances to one specific location
 Capture getCapture(int row)
          returns the capture stored at a given row of the Vector
 SpatialVector getCenterLocation()
          returns the average neighbor distance
 boolean getConnect()
          returns whether the Capture should be visually connected
 Constraint getConstraint()
          returns the spatial constraint for the population
 SpatialVector getCurrentLocation()
          returns the current location for the animal
 DataTable getDistanceMatrix(int DistanceMeasure)
          calculates a matrix of distances between all valid (i.e., selected and non-missing) locations
 NumberVariable getDistancesToLocation(SpatialVector aLocation)
          returns the distances to one specific location
 Capture getEndCapture()
          returns the end capture for the animal
 double getEndTime()
          returns the start time for the animal
 double getFractalDimension()
          returns the fractal dimension of the coordinates
 double getFractalDimension(double stepSize)
          returns the fractal dimension of the coordinates
 Descriptives[] getGroupDescriptives(Variable theXVar)
          returns the descriptives for the groups identified by X
 java.awt.Polygon getHomeRange_MinimumPolygon()
          returns the average neighbor distance
 ANOVAResults getHotellingFResults(Variable theXVar)
          lists the results from an analysis of differences in mean angles for a variable of locations
 CaptureVariable getLatLongAsDistances()
          if the Captures are defined in longitude and latitude then this function converts these to distanced measures in meters using Haversines
 double getMeanDistanceToLocation(SpatialVector meanVec)
          returns the average neighbor distance
 double getMinNeighborDistance()
          returns the minimum neighbor distance
 NumberVariable getMoveDistances()
          creates and returns a variable containing the series of distances between captures
 MoveVariable getMoves()
          creates and returns a variable containing the series of absolute moves between captures
 MoveVariable getMoves(boolean relative)
          creates and returns a variable containing the series of absolute moves between captures
 double getNetDisplacement()
          returns the time difference between first and last capture
 MoveVector getNetMove()
          returns the time difference between first and last capture
 double getNetTime()
          returns the time difference between first and last capture
 SpatialDescriptives getSpatialDescriptives()
          fills the descriptive statistics for the variable and returns the results
 SpatialVector getSpatialVector(int row)
          returns the capture stored at a given row of the Vector
 NumberVariable getSpeeds()
          creates and returns a variable containing the series of speeds between captures
 SquaresCrossproducts getSSCP()
          returns the sums of squares and crossproducts for the variable
 Capture getStartCapture()
          returns the start capture for the animal
 double getStartTime()
          returns the start time for the animal
 java.lang.String getStringValue(int row)
          returns the capture stored at a given row of the Vector as a String
 NumberVariable getTimeBetweenFrames()
          creates and returns a variable containing the series of time distances between captures
 TimeVariable getTimeRefs()
          creates and returns a variable containing the times for these captures
 IntegerVariable getTimes()
          creates and returns a variable containing the times for these captures
 CaptureVariable getTinyStepPath(int nSteps)
          traces the current selected path in small increments
 NumberVariable getXs()
          returns the x coordinates as a Vector
 NumberVariable getYs()
          returns the x coordinates as a Vector
 NumberVariable getZs()
          returns the x coordinates as a Vector
 void listCircularDescriptives(boolean relative)
          lists the descriptive statistics for the angles of the moves using the currently selected set of rows
 void listDistanceMatrix(int DistanceMeasure)
          lists a matrix of distances between all valid (i.e., selected and non-missing) locations
 void listFractalDimension()
          lists the fractal dimension for the variable using the currently selected set of rows
 void listFractalDimension(double stepSize)
          lists the fractal dimension for the variable using the currently selected set of rows
 void listGroupDescriptives(Variable theXVar)
          lists the descriptives for the groups identified by X
 void listMoveDescriptives(boolean relative)
          lists the descriptive statistics for the moves using the currently selected set of rows
 void makeNewDescriptives()
          create a new set of descriptives for the variable the object
 SpatialVector reMapInConstraint(SpatialVector aCapture)
          remaps a capture for a given constraint
 CaptureVariable[] resamplePath(double[] distUnits)
          retraces the path with different step lengths
 void selectAbove(double cutoffX, double cutoffY, double cutoffZ, boolean fromPrevSelected)
          select all rows with a value greater than the one provided
 void selectAboveDistance(double distanceCutoff, boolean fromPrevSelected)
          select all rows with a value less than the one provided
 void selectAboveEqual(double cutoffX, double cutoffY, double cutoffZ, boolean fromPrevSelected)
          select all rows with a value greater than the one provided
 void selectAboveSpeed(double speedCutoff, boolean fromPrevSelected)
          select all rows with a value less than the one provided
 void selectAfter(long cutoffTime, boolean fromPrevSelected)
          select all rows with a value greater than the one provided
 void selectAfterEqual(long cutoffTime, boolean fromPrevSelected)
          select all rows with a value greater than the one provided
 void selectBefore(long cutoffTime, boolean fromPrevSelected)
          select all rows with a value greater than the one provided
 void selectBeforeEqual(long cutoffTime, boolean fromPrevSelected)
          select all rows with a value greater than the one provided
 void selectBelow(double cutoffX, double cutoffY, double cutoffZ, boolean fromPrevSelected)
          select all rows with a value less than the one provided
 void selectBelowDistance(double distanceCutoff, boolean fromPrevSelected)
          select all rows with a value less than the one provided
 void selectBelowEqual(double cutoffX, double cutoffY, double cutoffZ, boolean fromPrevSelected)
          select all rows with a value less or equal than the one provided
 void selectBelowSpeed(double speedCutoff, boolean fromPrevSelected)
          select all rows with a value less than the one provided
 void selectBetween(long sCutoffTime, long eCutoffTime, boolean fromPrevSelected)
          select all rows with a value greater equal the start time and less or equal the end time
 void selectInArea(GridSpace3D a3DBox, boolean fromPrevSelected)
          select all rows with a value locatad within the 3D box
 void selectXAbove(double cutoffX, boolean fromPrevSelected)
          select all rows with an X value greater than the one provided
 void selectXAboveEqual(double cutoffX, boolean fromPrevSelected)
          select all rows with an X value greater or equal than the one provided
 void selectXBelow(double cutoffX, boolean fromPrevSelected)
          select all rows with an X value less than the one provided
 void selectXBelowEqual(double cutoffX, boolean fromPrevSelected)
          select all rows with an X value less or equal than the one provided
 void selectYAbove(double cutoffY, boolean fromPrevSelected)
          select all rows with a Y value greater than the one provided
 void selectYAboveEqual(double cutoffY, boolean fromPrevSelected)
          select all rows with a Y value greater or equal than the one provided
 void selectYBelow(double cutoffY, boolean fromPrevSelected)
          select all rows with a Y value less than the one provided
 void selectYBelowEqual(double cutoffY, boolean fromPrevSelected)
          select all rows with a Y value less or equal than the one provided
 void selectZAbove(double cutoffZ, boolean fromPrevSelected)
          select all rows with a Z value greater than the one provided
 void selectZAboveEqual(double cutoffZ, boolean fromPrevSelected)
          select all rows with a Z value greater or equal than the one provided
 void selectZBelow(double cutoffZ, boolean fromPrevSelected)
          select all rows with a Z value less than the one provided
 void selectZBelowEqual(double cutoffZ, boolean fromPrevSelected)
          select all rows with a Z value less or equal than the one provided
 void setConnect(boolean connect)
          sets whether the Captures should be visually connected
 void setConstraint(Constraint aConstraint)
          install a spatial constraint for the variable
 void setExternalMovesDistribution(MoveVariable theMoves)
          install an external distribution of Moves to sample from
 void setMaxMovingThreshold(float maxMovingThreshold)
          sets the maximum threshold for the distance an animal may move to be considered a valid travel
 void setMinMovingThreshold(float minMovingThreshold)
          sets the threshold for the distance an animal may move to be considered a valid travel
 void writeKMLCoords(java.io.Writer output)
          export the CaptureVariable's LineStyle into a KML file for display in Google Earth
 void writeKMLFile()
          export the coordinates into a KML file for display in Google Earth
 void writeKMLFile(java.lang.String name)
          export the coordinates into a KML file for display in Google Earth
 void writeKMLIntro(java.io.Writer output)
          export the CaptureVariable's LineStyle into a KML file for display in Google Earth
 void writeKMLLine(java.io.Writer output)
          export the CaptureVariable's coordinates into a KML file for display in Google Earth
 void writeKMLLineStyle(java.io.Writer output)
          export the CaptureVariable's LineStyle into a KML file for display in Google Earth
 void writeKMLOutro(java.io.Writer output)
          export the CaptureVariable's LineStyle into a KML file for display in Google Earth
 void writeKMLPoints(java.io.Writer output)
          export the CaptureVariable's coordinates into a KML file for display in Google Earth
 
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
 

Field Detail

latlong

public boolean latlong
Constructor Detail

CaptureVariable

public CaptureVariable(java.lang.String varName,
                       VariableOrganizer theOrganizer)
                throws java.lang.Exception
Standard constructor for the CaptureVariable 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

setConnect

public void setConnect(boolean connect)
sets whether the Captures should be visually connected

Parameters:
connect - should the Captures be connected?

getConnect

public boolean getConnect()
returns whether the Capture should be visually connected


checkConnectedCoords

public boolean checkConnectedCoords()
                             throws java.lang.Exception
assures that coordinates are connected

Throws:
java.lang.Exception

addMove

public void addMove(MoveVector aMove)
makes the animal move from the last recorded position

Parameters:
aMove - the next move

fill

public void fill(java.awt.Polygon poly)
          throws java.lang.Exception
fills the variable with locations from x and y coordinates that mark the corners of a polygon. Captures have time stamp 0

Parameters:
poly - Polygon containing x,y coordinates
Throws:
java.lang.Exception

fill

public void fill(NumberVariable x,
                 NumberVariable y)
          throws java.lang.Exception
Fills the variable with captures, x and y variable from the same row are assumed to belong together

Parameters:
x - the x coordinates
y - the y coordinates
Throws:
java.lang.Exception

fill

public void fill(NumberVariable x,
                 NumberVariable y,
                 NumberVariable z,
                 TimeVariable time)
          throws java.lang.Exception
Fills the variable with captures, x and y variable from the same row are assumed to belong together

Parameters:
x - the x coordinates
y - the y coordinates
z - the z coordinates
time - the time stamp for the capture
Throws:
java.lang.Exception

fill

public void fill(NumberVariable x,
                 NumberVariable y,
                 TimeVariable time)
          throws java.lang.Exception
Fills the variable with captures, x and y variable from the same row are assumed to belong together

Parameters:
x - the x coordinates
y - the y coordinates
time - the time stamp for the capture
Throws:
java.lang.Exception

fill

public void fill(PolarVector[] aVecs)
          throws java.lang.Exception
fills the variable with captures

Parameters:
aVecs - an array of polar vectors
Throws:
java.lang.Exception

fill

public void fill(SpatialVector[] aVecs)
          throws java.lang.Exception
fills the variable with captures

Parameters:
aVecs - an array of spatial vectors
Throws:
java.lang.Exception

fillWithGaussRandom

public void fillWithGaussRandom(Capture StartCapture,
                                double theMean,
                                double theSD,
                                boolean is3D)
                         throws java.lang.Exception
fills the variable with random values from a uniform distribution between 0 and 1

Parameters:
StartCapture - the Capture that describes the starting point
theMean - the mean distance
theSD - the standard deviation for distances
is3D - are all 3 dimensions used?
Throws:
java.lang.Exception

fillWithRandomFromDistribution

public void fillWithRandomFromDistribution(Capture StartCapture)
                                    throws java.lang.Exception
fills the variable with random values from a Distribution of Moves

Parameters:
StartCapture - first position at which the animal is captured
Throws:
java.lang.Exception

cloneSelectedRowsOnly

public Variable cloneSelectedRowsOnly()
                               throws java.lang.Exception
returns a copy of the CaptureVariable contianing only the selected rows

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

selectBefore

public void selectBefore(long cutoffTime,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with a value greater than the one provided

Parameters:
cutoffTime - lists the comparison value for the time
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectBeforeEqual

public void selectBeforeEqual(long cutoffTime,
                              boolean fromPrevSelected)
                       throws java.lang.Exception
select all rows with a value greater than the one provided

Parameters:
cutoffTime - lists the comparison value for the time
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectAfter

public void selectAfter(long cutoffTime,
                        boolean fromPrevSelected)
                 throws java.lang.Exception
select all rows with a value greater than the one provided

Parameters:
cutoffTime - lists the comparison value for the time
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectAfterEqual

public void selectAfterEqual(long cutoffTime,
                             boolean fromPrevSelected)
                      throws java.lang.Exception
select all rows with a value greater than the one provided

Parameters:
cutoffTime - lists the comparison value for the time
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectBetween

public void selectBetween(long sCutoffTime,
                          long eCutoffTime,
                          boolean fromPrevSelected)
                   throws java.lang.Exception
select all rows with a value greater equal the start time and less or equal the end time

Parameters:
sCutoffTime - the start time
eCutoffTime - the start time
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectAbove

public void selectAbove(double cutoffX,
                        double cutoffY,
                        double cutoffZ,
                        boolean fromPrevSelected)
                 throws java.lang.Exception
select all rows with a value greater than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
cutoffY - lists the comparison value for the y Coordinate
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectAboveEqual

public void selectAboveEqual(double cutoffX,
                             double cutoffY,
                             double cutoffZ,
                             boolean fromPrevSelected)
                      throws java.lang.Exception
select all rows with a value greater than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
cutoffY - lists the comparison value for the y Coordinate
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectBelow

public void selectBelow(double cutoffX,
                        double cutoffY,
                        double cutoffZ,
                        boolean fromPrevSelected)
                 throws java.lang.Exception
select all rows with a value less than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
cutoffY - lists the comparison value for the y Coordinate
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectBelowEqual

public void selectBelowEqual(double cutoffX,
                             double cutoffY,
                             double cutoffZ,
                             boolean fromPrevSelected)
                      throws java.lang.Exception
select all rows with a value less or equal than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
cutoffY - lists the comparison value for the y Coordinate
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectXBelowEqual

public void selectXBelowEqual(double cutoffX,
                              boolean fromPrevSelected)
                       throws java.lang.Exception
select all rows with an X value less or equal than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectXBelow

public void selectXBelow(double cutoffX,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with an X value less than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectXAboveEqual

public void selectXAboveEqual(double cutoffX,
                              boolean fromPrevSelected)
                       throws java.lang.Exception
select all rows with an X value greater or equal than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectXAbove

public void selectXAbove(double cutoffX,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with an X value greater than the one provided

Parameters:
cutoffX - lists the comparison value for the x Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectYBelowEqual

public void selectYBelowEqual(double cutoffY,
                              boolean fromPrevSelected)
                       throws java.lang.Exception
select all rows with a Y value less or equal than the one provided

Parameters:
cutoffY - lists the comparison value for the y Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectYBelow

public void selectYBelow(double cutoffY,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with a Y value less than the one provided

Parameters:
cutoffY - lists the comparison value for the y Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectYAboveEqual

public void selectYAboveEqual(double cutoffY,
                              boolean fromPrevSelected)
                       throws java.lang.Exception
select all rows with a Y value greater or equal than the one provided

Parameters:
cutoffY - lists the comparison value for the y Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectYAbove

public void selectYAbove(double cutoffY,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with a Y value greater than the one provided

Parameters:
cutoffY - lists the comparison value for the y Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectZBelowEqual

public void selectZBelowEqual(double cutoffZ,
                              boolean fromPrevSelected)
                       throws java.lang.Exception
select all rows with a Z value less or equal than the one provided

Parameters:
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectZBelow

public void selectZBelow(double cutoffZ,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with a Z value less than the one provided

Parameters:
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectZAboveEqual

public void selectZAboveEqual(double cutoffZ,
                              boolean fromPrevSelected)
                       throws java.lang.Exception
select all rows with a Z value greater or equal than the one provided

Parameters:
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectZAbove

public void selectZAbove(double cutoffZ,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with a Z value greater than the one provided

Parameters:
cutoffZ - lists the comparison value for the z Coordinate
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectInArea

public void selectInArea(GridSpace3D a3DBox,
                         boolean fromPrevSelected)
                  throws java.lang.Exception
select all rows with a value locatad within the 3D box

Parameters:
a3DBox - a 3D space
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectBelowSpeed

public void selectBelowSpeed(double speedCutoff,
                             boolean fromPrevSelected)
                      throws java.lang.Exception
select all rows with a value less than the one provided

Parameters:
speedCutoff - lists the maximum speed allowed for selction
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectAboveSpeed

public void selectAboveSpeed(double speedCutoff,
                             boolean fromPrevSelected)
                      throws java.lang.Exception
select all rows with a value less than the one provided

Parameters:
speedCutoff - lists the maximum speed allowed for selection
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectAboveDistance

public void selectAboveDistance(double distanceCutoff,
                                boolean fromPrevSelected)
                         throws java.lang.Exception
select all rows with a value less than the one provided

Parameters:
distanceCutoff - lists the maximum distance allowed for selection
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

selectBelowDistance

public void selectBelowDistance(double distanceCutoff,
                                boolean fromPrevSelected)
                         throws java.lang.Exception
select all rows with a value less than the one provided

Parameters:
distanceCutoff - lists the maximum speed allowed for selection
fromPrevSelected - notes whether the search should only be performed on currently selected rows
Throws:
java.lang.Exception

setExternalMovesDistribution

public void setExternalMovesDistribution(MoveVariable theMoves)
install an external distribution of Moves to sample from

Parameters:
theMoves - a distribution from which to sample random moves and apply them to the current position

setConstraint

public void setConstraint(Constraint aConstraint)
                   throws java.lang.Exception
install a spatial constraint for the variable

Parameters:
aConstraint - a spatial constraint for the CaptureVariable
Throws:
java.lang.Exception

getConstraint

public Constraint getConstraint()
                         throws java.lang.Exception
returns the spatial constraint for the population

Throws:
java.lang.Exception

reMapInConstraint

public SpatialVector reMapInConstraint(SpatialVector aCapture)
                                throws java.lang.Exception
remaps a capture for a given constraint

Parameters:
aCapture - the capture to remap
Throws:
java.lang.Exception

getCapture

public Capture getCapture(int row)
returns the capture stored at a given row of the Vector

Parameters:
row - marks the row in the vector

getXs

public NumberVariable getXs()
                     throws java.lang.Exception
returns the x coordinates as a Vector

Throws:
java.lang.Exception

getYs

public NumberVariable getYs()
                     throws java.lang.Exception
returns the x coordinates as a Vector

Throws:
java.lang.Exception

getZs

public NumberVariable getZs()
                     throws java.lang.Exception
returns the x coordinates as a Vector

Throws:
java.lang.Exception

getSpatialVector

public SpatialVector getSpatialVector(int row)
returns the capture stored at a given row of the Vector

Parameters:
row - marks the row in the vector

applyRandomMoveFromDistribution

public MoveVector applyRandomMoveFromDistribution(Capture StartCapture)
                                           throws java.lang.Exception
generates a single move from a Distribution of Moves

Parameters:
StartCapture - first position at which the animal is captured
Throws:
java.lang.Exception

getStringValue

public java.lang.String getStringValue(int row)
returns the capture stored at a given row of the Vector as a String

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

setMinMovingThreshold

public void setMinMovingThreshold(float minMovingThreshold)
sets the threshold for the distance an animal may move to be considered a valid travel

Parameters:
minMovingThreshold - the value to set

setMaxMovingThreshold

public void setMaxMovingThreshold(float maxMovingThreshold)
sets the maximum threshold for the distance an animal may move to be considered a valid travel

Parameters:
maxMovingThreshold - the value to set

getCurrentLocation

public SpatialVector getCurrentLocation()
                                 throws java.lang.Exception
returns the current location for the animal

Throws:
java.lang.Exception

getStartCapture

public Capture getStartCapture()
                        throws java.lang.Exception
returns the start capture for the animal

Throws:
java.lang.Exception

getStartTime

public double getStartTime()
                    throws java.lang.Exception
returns the start time for the animal

Throws:
java.lang.Exception

getEndCapture

public Capture getEndCapture()
                      throws java.lang.Exception
returns the end capture for the animal

Throws:
java.lang.Exception

getEndTime

public double getEndTime()
                  throws java.lang.Exception
returns the start time for the animal

Throws:
java.lang.Exception

getNetTime

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

Throws:
java.lang.Exception

getLatLongAsDistances

public CaptureVariable getLatLongAsDistances()
                                      throws java.lang.Exception
if the Captures are defined in longitude and latitude then this function converts these to distanced measures in meters using Haversines

Throws:
java.lang.Exception

getTimeRefs

public TimeVariable getTimeRefs()
                         throws java.lang.Exception
creates and returns a variable containing the times for these captures

Throws:
java.lang.Exception

getTimes

public IntegerVariable getTimes()
                         throws java.lang.Exception
creates and returns a variable containing the times for these captures

Throws:
java.lang.Exception

getMoves

public MoveVariable getMoves()
                      throws java.lang.Exception
creates and returns a variable containing the series of absolute moves between captures

Throws:
java.lang.Exception

getMoves

public MoveVariable getMoves(boolean relative)
                      throws java.lang.Exception
creates and returns a variable containing the series of absolute moves between captures

Parameters:
relative - are the moves relative to the previous move?
Throws:
java.lang.Exception

getMoveDistances

public NumberVariable getMoveDistances()
                                throws java.lang.Exception
creates and returns a variable containing the series of distances between captures

Throws:
java.lang.Exception

getNetMove

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

Throws:
java.lang.Exception

getNetDisplacement

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

Throws:
java.lang.Exception

getTinyStepPath

public CaptureVariable getTinyStepPath(int nSteps)
                                throws java.lang.Exception
traces the current selected path in small increments

Parameters:
nSteps - the number of increments in the path
Throws:
java.lang.Exception

getSpeeds

public NumberVariable getSpeeds()
                         throws java.lang.Exception
creates and returns a variable containing the series of speeds between captures

Throws:
java.lang.Exception

getTimeBetweenFrames

public NumberVariable getTimeBetweenFrames()
                                    throws java.lang.Exception
creates and returns a variable containing the series of time distances between captures

Throws:
java.lang.Exception

getSSCP

public SquaresCrossproducts getSSCP()
                             throws java.lang.Exception
returns the sums of squares and crossproducts for the variable

Throws:
java.lang.Exception

getHotellingFResults

public ANOVAResults getHotellingFResults(Variable theXVar)
                                  throws java.lang.Exception
lists the results from an analysis of differences in mean angles for a variable of locations

Parameters:
theXVar - variable that contains grouping information
Throws:
java.lang.Exception

getDistanceMatrix

public DataTable getDistanceMatrix(int DistanceMeasure)
                            throws java.lang.Exception
calculates a matrix of distances between all valid (i.e., selected and non-missing) locations

Parameters:
DistanceMeasure - what type of distance measure should be calculated
Throws:
java.lang.Exception

listDistanceMatrix

public void listDistanceMatrix(int DistanceMeasure)
                        throws java.lang.Exception
lists a matrix of distances between all valid (i.e., selected and non-missing) locations

Parameters:
DistanceMeasure - what type of distance measure should be calculated
Throws:
java.lang.Exception

getMinNeighborDistance

public double getMinNeighborDistance()
                              throws java.lang.Exception
returns the minimum neighbor distance

Throws:
java.lang.Exception

getDistancesToLocation

public NumberVariable getDistancesToLocation(SpatialVector aLocation)
                                      throws java.lang.Exception
returns the distances to one specific location

Parameters:
aLocation - the location to which distances are calculated
Throws:
java.lang.Exception

getAnglesFromCenter

public NumberVariable getAnglesFromCenter()
                                   throws java.lang.Exception
returns the distances to one specific location

Throws:
java.lang.Exception

getCenterLocation

public SpatialVector getCenterLocation()
                                throws java.lang.Exception
returns the average neighbor distance

Throws:
java.lang.Exception

getMeanDistanceToLocation

public double getMeanDistanceToLocation(SpatialVector meanVec)
                                 throws java.lang.Exception
returns the average neighbor distance

Throws:
java.lang.Exception

getHomeRange_MinimumPolygon

public java.awt.Polygon getHomeRange_MinimumPolygon()
                                             throws java.lang.Exception
returns the average neighbor distance

Throws:
java.lang.Exception

resamplePath

public CaptureVariable[] resamplePath(double[] distUnits)
                               throws java.lang.Exception
retraces the path with different step lengths

Parameters:
distUnits - an array of pathlengths
Throws:
java.lang.Exception

estimateD

public double estimateD(double maxPathLength,
                        double stepSize,
                        double pathLength)
                 throws java.lang.Exception
returns the fractal dimension of the coordinates

Throws:
java.lang.Exception

getFractalDimension

public double getFractalDimension()
                           throws java.lang.Exception
returns the fractal dimension of the coordinates

Throws:
java.lang.Exception

getFractalDimension

public double getFractalDimension(double stepSize)
                           throws java.lang.Exception
returns the fractal dimension of the coordinates

Parameters:
stepSize - the original step size of the individual producing the path, use 0 for default
Throws:
java.lang.Exception

listFractalDimension

public void listFractalDimension()
                          throws java.lang.Exception
lists the fractal dimension for the variable using the currently selected set of rows

Throws:
java.lang.Exception

listFractalDimension

public void listFractalDimension(double stepSize)
                          throws java.lang.Exception
lists the fractal dimension for the variable using the currently selected set of rows

Parameters:
stepSize - the original step size of the individual producing the path, use 0 for default
Throws:
java.lang.Exception

makeNewDescriptives

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

Overrides:
makeNewDescriptives in class Variable

fillDescriptives

public void fillDescriptives(java.lang.Double hypVal)
                      throws java.lang.Exception
fills the descriptive statistics for the variable - locations

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

getSpatialDescriptives

public SpatialDescriptives getSpatialDescriptives()
                                           throws java.lang.Exception
fills the descriptive statistics for the variable and returns the results

Throws:
java.lang.Exception

copySpatialDescriptives

public SpatialDescriptives copySpatialDescriptives()
                                            throws java.lang.Exception
fills the descriptive statistics for the variable and returns the results

Throws:
java.lang.Exception

getGroupDescriptives

public Descriptives[] getGroupDescriptives(Variable theXVar)
                                    throws java.lang.Exception
returns the descriptives for the groups identified by X

Parameters:
theXVar - the independent variable contains information about the experimental group for each case
Throws:
java.lang.Exception

listGroupDescriptives

public void listGroupDescriptives(Variable theXVar)
                           throws java.lang.Exception
lists the descriptives for the groups identified by X

Overrides:
listGroupDescriptives in class Variable
Parameters:
theXVar - the independent variable contains information about the experimental group for each case
Throws:
java.lang.Exception

listMoveDescriptives

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

Parameters:
relative - are the moves relative to the previous move?
Throws:
java.lang.Exception

listCircularDescriptives

public void listCircularDescriptives(boolean relative)
                              throws java.lang.Exception
lists the descriptive statistics for the angles of the moves using the currently selected set of rows

Parameters:
relative - are the moves relative to the previous move?
Throws:
java.lang.Exception

asSpatialMap

public void asSpatialMap()
                  throws java.lang.Exception
Creates a presenter and plots and connects the locations

Throws:
java.lang.Exception

asSpatialMap

public void asSpatialMap(boolean xDirection,
                         boolean yDirection)
                  throws java.lang.Exception
Creates a presenter and plots the locations

Parameters:
xDirection - do x values increase from left to right?
yDirection - do y values increase from top to bottom?
Throws:
java.lang.Exception

asSpatialMap

public void asSpatialMap(boolean xDirection,
                         boolean yDirection,
                         int view)
                  throws java.lang.Exception
Creates a presenter and plots the locations

Parameters:
xDirection - do x values increase from left to right?
yDirection - do y values increase from top to bottom?
view - 0 - XY, 1 - XZ, 2 - YZ;
Throws:
java.lang.Exception

asSpatialSpeedMap

public void asSpatialSpeedMap()
                       throws java.lang.Exception
Creates a presenter and plots and connects the locations

Throws:
java.lang.Exception

asSpatialSpeedMap

public void asSpatialSpeedMap(boolean xDirection,
                              boolean yDirection)
                       throws java.lang.Exception
Creates a presenter and plots the locations

Parameters:
xDirection - do x values increase from left to right?
yDirection - do y values increase from top to bottom?
Throws:
java.lang.Exception

asCircularGraph

public void asCircularGraph()
                     throws java.lang.Exception
Creates a circular presenter

Throws:
java.lang.Exception

asCircularGraph

public void asCircularGraph(boolean relative)
                     throws java.lang.Exception
Creates a circular presenter

Parameters:
relative - should the direction of the moves be considered relative to the previous direction
Throws:
java.lang.Exception

writeKMLIntro

public void writeKMLIntro(java.io.Writer output)
                   throws java.lang.Exception
export the CaptureVariable's LineStyle into a KML file for display in Google Earth

Throws:
java.lang.Exception

writeKMLLineStyle

public void writeKMLLineStyle(java.io.Writer output)
                       throws java.lang.Exception
export the CaptureVariable's LineStyle into a KML file for display in Google Earth

Throws:
java.lang.Exception

writeKMLLine

public void writeKMLLine(java.io.Writer output)
                  throws java.lang.Exception
export the CaptureVariable's coordinates into a KML file for display in Google Earth

Throws:
java.lang.Exception

writeKMLPoints

public void writeKMLPoints(java.io.Writer output)
                    throws java.lang.Exception
export the CaptureVariable's coordinates into a KML file for display in Google Earth

Throws:
java.lang.Exception

writeKMLOutro

public void writeKMLOutro(java.io.Writer output)
                   throws java.lang.Exception
export the CaptureVariable's LineStyle into a KML file for display in Google Earth

Throws:
java.lang.Exception

writeKMLCoords

public void writeKMLCoords(java.io.Writer output)
                    throws java.lang.Exception
export the CaptureVariable's LineStyle into a KML file for display in Google Earth

Throws:
java.lang.Exception

writeKMLFile

public void writeKMLFile()
                  throws java.lang.Exception
export the coordinates into a KML file for display in Google Earth

Throws:
java.lang.Exception

writeKMLFile

public void writeKMLFile(java.lang.String name)
                  throws java.lang.Exception
export the coordinates into a KML file for display in Google Earth

Throws:
java.lang.Exception