Home | Trees | Index | Help |
|
---|
Package xdp :: Module dataset :: Class Data |
|
ExperimentData
,
XafsData
Store columns of data and their associated names.
These columns can be maniplulated by the get(), add(), and set() methods or by accessing the columns as though they are attributes of the object.Method Summary | |
---|---|
Create an empty dataset. | |
Allow columns to be accessed as attributes. | |
Allow columns to be set as attributes. | |
Create a new column of data. | |
Create a new column of data. | |
list of str ings
|
Retrieve a list of the column names. |
xdp.Data
|
Create a copy of this dataset. |
any |
Evaluate a Python expression using this dataset's column names |
Numeric vector
|
Retrieve a column's data. |
Numeric vector
|
Retrieve a column's data. |
list of str ings
|
Retrieve a list of the column names. |
Numeric matrix
|
Construct a matrix out of this dataset. |
bool
|
Check for the presence of a column. |
bool
|
Check for the presence of a column. |
Remove a column. | |
Remove a column. | |
Rename a column. | |
Rename a column. | |
Assign data to a column. | |
Assign data to a column. | |
Numeric vector
|
Retrieve data by column number. |
|
Convert a value from a column number into a column name. |
Remove a column by its column number. | |
Assign data by column number. |
Class Variable Summary | |
---|---|
compiled regular expression | COLNAMES : used by Data.evaluate to match and replace the
@X column names in expressions |
compiled regular expression | COLNUMS : used by Data.evaluate to match and replace the
@X column numbers in expressions |
dict |
EVAL_NAMESPACE : used by Data.evaluate as the default namespace for
evaluating Python expressions |
Method Details |
---|
__init__(self,
**kwds)
|
__getattr__(self,
name)
Allow columns to be accessed as attributes.
|
__setattr__(self, name, value)Allow columns to be set as attributes.
|
add(self, name, vector)Create a new column of data.
|
addColumn(self, name, vector)Create a new column of data.
|
columns(self)Retrieve a list of the column names.
|
copy(self, deep=1)Create a copy of this dataset.
|
evaluate(self, expr)Evaluate a Python expression using this dataset's column names Column names are prefixes by an at sign, and may contain the name
(
Numeric are
ufunc s; they will operate correctly on vectors.
|
get(self, name)Retrieve a column's data. name may be the column's name, a column index, or a
string containing a column index.
|
getColumn(self, name)Retrieve a column's data. name may be the column's name, a column index, or a
string containing a column index.
|
getColumnNames(self)Retrieve a list of the column names.
|
getMatrix(self)Construct a matrix out of this dataset.
|
has(self, name)Check for the presence of a column.
|
hasColumn(self, name)Check for the presence of a column.
|
remove(self, name)Remove a column.
|
removeColumn(self, name)Remove a column.
|
rename(self, name, newName)Rename a column.
|
renameColumn(self, name, newName)Rename a column.
|
set(self, name, vector)Assign data to a column. If the column does not exist, it will be created.
|
setColumn(self, name, vector)Assign data to a column. If the column does not exist, it will be created.
|
__getByIndex(self, index)Retrieve data by column number.
|
__getIndex(self, name)Convert a value from a column number into a column name. This method returnsNone if name is not a
valid column number.
|
__removeByIndex(self, index)Remove a column by its column number.
|
__setByIndex(self, index, vector)Assign data by column number.
|
Class Variable Details |
---|
COLNAMESused byData.evaluate to match and replace the
@X column names in expressions
|
COLNUMSused byData.evaluate to match and replace the
@X column numbers in expressions
|
Home | Trees | Index | Help |
|
---|
Generated by Epydoc 2.1 on Wed Jul 20 11:51:06 2005 | http://epydoc.sf.net |