Specialized data column representing categorical values, i.e. strings. Categorical values are internally mapped to a number representation.
More...
|
| CategoricalColumn (const std::string &header) |
|
| CategoricalColumn (const CategoricalColumn &rhs)=default |
|
| CategoricalColumn (CategoricalColumn &&rhs)=default |
|
CategoricalColumn & | operator= (const CategoricalColumn &rhs)=default |
|
CategoricalColumn & | operator= (CategoricalColumn &&rhs)=default |
|
virtual CategoricalColumn * | clone () const override |
|
virtual std::string | getAsString (size_t idx) const override |
|
virtual std::shared_ptr< DataPointBase > | get (size_t idx, bool getStringsAsStrings) const override |
| returns either the categorical value, i.e. a number representation, or the actual string for the given index. More...
|
|
virtual void | set (size_t idx, const std::string &str) |
|
virtual void | add (const std::string &value) override |
| converts given value to type T, which is added to the column More...
|
|
const std::vector< std::string > & | getCategories () const |
|
Public Member Functions inherited from inviwo::TemplateColumn< std::uint32_t > |
| TemplateColumn (const std::string &header) |
|
| TemplateColumn (const TemplateColumn< std::uint32_t > &rhs) |
|
| TemplateColumn (TemplateColumn< std::uint32_t > &&rhs) |
|
TemplateColumn< std::uint32_t > & | operator= (const TemplateColumn< std::uint32_t > &rhs) |
|
TemplateColumn< std::uint32_t > & | operator= (TemplateColumn< std::uint32_t > &&rhs) |
|
virtual const std::string & | getHeader () const override |
|
void | setHeader (const std::string &header) override |
|
virtual void | add (const std::uint32_t &value) |
|
virtual void | set (size_t idx, const std::uint32_t &value) |
|
std::uint32_t | get (size_t idx) const |
|
virtual double | getAsDouble (size_t idx) const override |
|
virtual dvec2 | getAsDVec2 (size_t idx) const override |
|
virtual dvec3 | getAsDVec3 (size_t idx) const override |
|
virtual dvec4 | getAsDVec4 (size_t idx) const override |
|
void | setBuffer (std::shared_ptr< Buffer< std::uint32_t >> buffer) |
|
virtual std::shared_ptr< BufferBase > | getBuffer () override |
|
virtual std::shared_ptr< const BufferBase > | getBuffer () const override |
|
std::shared_ptr< Buffer< std::uint32_t > > | getTypedBuffer () |
|
std::shared_ptr< const Buffer< std::uint32_t > > | getTypedBuffer () const |
|
virtual size_t | getSize () const override |
|
Specialized data column representing categorical values, i.e. strings. Categorical values are internally mapped to a number representation.
For example: The data column "blue", "blue", "red", "yellow" might internally be represented by 0, 0, 1, 2. The original string values can be accessed using CategoricalColumn::get(index, true)
- See also
- TemplateColumn,
-
CategoricalColumn::get()