org.omegahat.Environment.DataStructures
Class BasicDataFrame

java.lang.Object
  |
  +--org.omegahat.Environment.Databases.ObjectDatabase
        |
        +--org.omegahat.Environment.DataStructures.BasicDataFrame
All Implemented Interfaces:
Activable, BasicFrame, Database, DatabaseNotifier, DataFrame, DynamicFieldAccessInt, MergableInt, Named, java.io.Serializable, Subsettable

public class BasicDataFrame
extends ObjectDatabase
implements DataFrame

See Also:
Serialized Form

Field Summary
protected  character RowNames
           
 
Fields inherited from class org.omegahat.Environment.Databases.ObjectDatabase
listeners, name, permissions, state, table, user
 
Fields inherited from interface org.omegahat.Environment.Databases.Database
ALL, ASSIGN, ATTACH, DETACH, NULL_ENTRY, READ, READ_WRITE, REMOVE
 
Fields inherited from interface org.omegahat.Environment.Databases.Activable
ACTIVE, INACTIVE
 
Constructor Summary
BasicDataFrame()
           
 
Method Summary
 Variable getVariable(java.lang.String name)
           
 java.lang.String[] getVariableNames()
          Return a (ordered) list of the names of the variables contained in this collection.
 long numObservations()
          Return the number of observations available in each of the variables.
 long numVariables()
          Return the number of variables contained in this frame.
 java.lang.String[] rowNames()
          Returns an array of the identifiers of the row names.
 character RowNames()
           
 character RowNames(character r)
           
 BasicFrame subsetObservations(int[] whichRows)
          Create a new data frame consisting of the rows identified in the array passed to this method.
 BasicFrame subsetObservations(int start, int which)
          Get the subset of the data frame of the continguous rows starting at start and ending at which, inclusive.
 
Methods inherited from class org.omegahat.Environment.Databases.ObjectDatabase
addAssignListener, addAttachListener, addDetachListener, addListener, addRemoveListener, assign, assign, attach, clear, detach, exists, get, getDynamicField, getName, getState, getTable, merge, merge, notify, objects, put, readOnly, readOnly, readSerialized, readSerialized, readSerialized, remove, remove, setDynamicField, setName, setState, setTable, size, subset, table, table
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RowNames

protected character RowNames
Constructor Detail

BasicDataFrame

public BasicDataFrame()
Method Detail

getVariableNames

public java.lang.String[] getVariableNames()
Description copied from interface: BasicFrame
Return a (ordered) list of the names of the variables contained in this collection.
Specified by:
getVariableNames in interface BasicFrame

numVariables

public long numVariables()
Description copied from interface: BasicFrame
Return the number of variables contained in this frame.
Specified by:
numVariables in interface BasicFrame

numObservations

public long numObservations()
Description copied from interface: BasicFrame
Return the number of observations available in each of the variables. This assumes that the variables have the same number of records/observations.
Specified by:
numObservations in interface BasicFrame

rowNames

public java.lang.String[] rowNames()
Description copied from interface: BasicFrame
Returns an array of the identifiers of the row names.
Specified by:
rowNames in interface BasicFrame

getVariable

public Variable getVariable(java.lang.String name)
Specified by:
getVariable in interface BasicFrame

subsetObservations

public BasicFrame subsetObservations(int[] whichRows)
Description copied from interface: DataFrame
Create a new data frame consisting of the rows identified in the array passed to this method.
Specified by:
subsetObservations in interface DataFrame

subsetObservations

public BasicFrame subsetObservations(int start,
                                     int which)
Description copied from interface: DataFrame
Get the subset of the data frame of the continguous rows starting at start and ending at which, inclusive.
Specified by:
subsetObservations in interface DataFrame

RowNames

public character RowNames()

RowNames

public character RowNames(character r)