public interface Column
Columns can either exist on their own or be a part of a table. All the data in a single column is of a particular type.
Modifier and Type | Method and Description |
---|---|
void |
append(Column column) |
void |
appendCell(String stringValue) |
byte[] |
asBytes(int rowNumber)
Returns the contents of the cell at rowNumber as a byte[].
|
int |
byteSize()
Returns the width of a cell in this column, in bytes.
|
void |
clear() |
ColumnMetadata |
columnMetadata() |
int |
columnWidth() |
String |
comment() |
Column |
copy()
Returns a deep copy of the receiver
|
int |
countMissing()
Returns the count of missing values in this column.
|
int |
countUnique()
Returns the count of unique values in this column.
|
Column |
difference()
Returns a new column of the same type as the receiver, such that the values in the new column
contain the difference between each cell in the original and it's predecessor.
|
Column |
emptyCopy()
Returns a copy of the receiver with no data.
|
Column |
emptyCopy(int rowSize)
Returns an empty copy of the receiver, with its internal storage initialized to the given row size.
|
default String |
first() |
default Column |
first(int numRows) |
String |
getString(int row)
Returns a string representation of the value at the given row.
|
String |
id()
Returns a unique string that identifies this column.
|
boolean |
isEmpty()
Returns true if the column has no data
|
Selection |
isMissing() |
Selection |
isNotMissing() |
default String |
last() |
default Column |
last(int numRows) |
String |
metadata()
Returns a String containing the column's metadata in json format.
|
String |
name()
Returns the column's name.
|
String |
print() |
default RollingColumn |
rolling(int windowSize) |
it.unimi.dsi.fastutil.ints.IntComparator |
rowComparator() |
void |
setComment(String comment) |
Column |
setName(String name)
Sets the columns name to the given string
|
int |
size() |
void |
sortAscending() |
void |
sortDescending() |
default Column |
subset(Selection rows) |
Table |
summary() |
default String |
title() |
default double[] |
toDoubleArray() |
ColumnType |
type()
Returns this column's ColumnType
|
Column |
unique()
Returns a column of the same type as the receiver, containing only the unique values of the receiver.
|
int size()
Table summary()
int countMissing()
int countUnique()
Column unique()
Column
String name()
Column setName(String name)
name
- The new name MUST be unique for any table containing this columnColumnType type()
ColumnType
String getString(int row)
row
- The index of the row.Column emptyCopy()
Column
Column emptyCopy(int rowSize)
rowSize
- the initial row sizeColumn
void clear()
void sortAscending()
void sortDescending()
boolean isEmpty()
void appendCell(String stringValue)
String id()
String metadata()
ColumnMetadata columnMetadata()
it.unimi.dsi.fastutil.ints.IntComparator rowComparator()
default String first()
default String last()
void append(Column column)
default Column first(int numRows)
default Column last(int numRows)
String print()
default String title()
String comment()
void setComment(String comment)
default double[] toDoubleArray()
int columnWidth()
Selection isMissing()
Selection isNotMissing()
int byteSize()
byte[] asBytes(int rowNumber)
rowNumber
- index of the rowColumn difference()
Column
default RollingColumn rolling(int windowSize)
Copyright © 2017. All rights reserved.