1.9.0
CCC
 
Loading...
Searching...
No Matches
Reading one or several Columns

Functions

 gstlrn::Db::getColumn (const String &name, bool useSel=false, bool flagCompress=true) const
 
 gstlrn::Db::getColumnByUID (Id iuid, bool useSel=false, bool flagCompress=true) const
 
 gstlrn::Db::getColumnByLocator (const ELoc &locatorType, Id locatorIndex=0, bool useSel=false, bool flagCompress=true) const
 
 gstlrn::Db::getColumnByColIdx (Id icol, bool useSel=false, bool flagCompress=true) const
 
 gstlrn::Db::getAllColumns (bool useSel=false, bool flagCompress=true) const
 
 gstlrn::Db::getColumns (const VectorString &names=VectorString(), bool useSel=false, bool flagCompress=true, const 1 &origins=1()) const
 
 gstlrn::Db::getColumnsAsVVD (const VectorString &names=VectorString(), bool useSel=false, bool flagCompress=true) const
 
MatrixDense gstlrn::Db::getColumnsAsMatrix (const VectorString &names, bool useSel=false, bool flagCompress=true) const
 
 gstlrn::Db::getColumnsByColIdx (const 1 &icols=1(), bool useSel=false, bool flagCompress=true, const 1 &origins=1()) const
 
 gstlrn::Db::getColumnsByColIdxInterval (Id icol_beg, Id icol_end, bool useSel=false, bool flagCompress=true) const
 
 gstlrn::Db::getColumnsActiveAndDefined (const ELoc &locatorType, const 1 &origins=1()) const
 
 gstlrn::Db::getColumnsByLocator (const ELoc &locatorType, bool useSel=false, bool flagCompress=true, const 1 &origins=1()) const
 
 gstlrn::Db::getColumnsByUID (const 1 &iuids, bool useSel=false, bool flagCompress=true, const 1 &origins=1()) const
 
 gstlrn::Db::getColumnsByUIDInterval (Id iuid_beg, Id iuid_end, bool useSel=false, bool flagCompress=true) const
 

Detailed Description

The column refers to one element of the Db (which can be viewed as an Excel spread sheet). Each variable stands as a column of this table: it is also attached a 'name' (which will serve as the name of the variable) and a possible 'locator' (which characterizes the role of the variable, e.g; coordinate, variable, code, ...). These functions can refer to a single column or to several of them. The columns can be referred to by the variable name, the column index, the internal Id (UID) or the locator.

Parameters
useSelOption when reading a masked sample:
  • TRUE: the contents of the masked samples is set to TEST
  • FALSE: the masked samples are returned with no impact of the selection
flagCompressOption when reading a masked sample:
  • TRUE: the returned array is compressed to the only non-masked samples
  • FALSE: the returned array is not compressed
nameName of the target column
namesVector of target variable names
locatorTypeType of target locator
iuidsVector of target user-identified ranks
icolsVector of Column ranks
icol_begLower bound of the rank interval (included)
icol_endUpper bound of the rank interval (excluded)
iuid_begLower bound of the user-identification interval (included)
iuid_endUpper bound of the user-identification interval (excluded)
locatorTypeType of the target locator
locatorIndexRank of the item (0-based) for the target locator
flagCompressWhen True, the masked values are skipped

Function Documentation

◆ getAllColumns()

gstlrn::Db::getAllColumns ( bool  useSel = false,
bool  flagCompress = true 
) const

Returns all the Columns contained in a Db

◆ getColumn()

gstlrn::Db::getColumn ( const String name,
bool  useSel = false,
bool  flagCompress = true 
) const

Returns the contents of one Column identified by its name

◆ getColumnByColIdx()

gstlrn::Db::getColumnByColIdx ( Id  icol,
bool  useSel = false,
bool  flagCompress = true 
) const

Returns the column referred by its rank (0-based)

◆ getColumnByLocator()

gstlrn::Db::getColumnByLocator ( const ELoc &  locatorType,
Id  locatorIndex = 0,
bool  useSel = false,
bool  flagCompress = true 
) const

Returns the contents of one Column identified by its locator type and item rank

◆ getColumnByUID()

gstlrn::Db::getColumnByUID ( Id  iuid,
bool  useSel = false,
bool  flagCompress = true 
) const

Returns a Column referred by its user-identification rank

◆ getColumns()

gstlrn::Db::getColumns ( const VectorString names = VectorString(),
bool  useSel = false,
bool  flagCompress = true,
const 1 &  origins = 1() 
) const

Returns the contents of the Colmuns specified by their names

◆ getColumnsActiveAndDefined()

gstlrn::Db::getColumnsActiveAndDefined ( const ELoc &  locatorType,
const 1 &  origins = 1() 
) const

◆ getColumnsAsMatrix()

MatrixDense gstlrn::Db::getColumnsAsMatrix ( const VectorString names,
bool  useSel = false,
bool  flagCompress = true 
) const

Returns the contents of the columns specified by their names

◆ getColumnsAsVVD()

gstlrn::Db::getColumnsAsVVD ( const VectorString names = VectorString(),
bool  useSel = false,
bool  flagCompress = true 
) const

Returns the contents of the Columns specified by their names (one variable per column)

◆ getColumnsByColIdx()

gstlrn::Db::getColumnsByColIdx ( const 1 &  icols = 1(),
bool  useSel = false,
bool  flagCompress = true,
const 1 &  origins = 1() 
) const

Returns the contents of a set of Columns specified by their ranks (0 based)

◆ getColumnsByColIdxInterval()

gstlrn::Db::getColumnsByColIdxInterval ( Id  icol_beg,
Id  icol_end,
bool  useSel = false,
bool  flagCompress = true 
) const

Returns the contents of a set of columns referred to by their rank interval (0 based)

◆ getColumnsByLocator()

gstlrn::Db::getColumnsByLocator ( const ELoc &  locatorType,
bool  useSel = false,
bool  flagCompress = true,
const 1 &  origins = 1() 
) const

Returns the contents of a set of Columns identified by the locator type

◆ getColumnsByUID()

gstlrn::Db::getColumnsByUID ( const 1 &  iuids,
bool  useSel = false,
bool  flagCompress = true,
const 1 &  origins = 1() 
) const

Returns the contents of a set of Columns identified by their user-identified ranks

◆ getColumnsByUIDInterval()

gstlrn::Db::getColumnsByUIDInterval ( Id  iuid_beg,
Id  iuid_end,
bool  useSel = false,
bool  flagCompress = true 
) const

Returns the contents of a set of columns specified by the interval of their user-identification ranks