public abstract class AbstractColumn<C extends Column<T>,T> extends Object implements Column<T>
Column interface| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_ARRAY_SIZE |
| Constructor and Description |
|---|
AbstractColumn(ColumnType type,
String name) |
| Modifier and Type | Method and Description |
|---|---|
StringColumn |
asStringColumn()
Returns a StringColumn consisting of the (unformatted) String representation of this column
values
|
abstract Column<T> |
emptyCopy()
Returns a copy of the receiver with no data.
|
C |
filter(Predicate<? super T> test)
Returns a new Column of the same type with only those rows satisfying the predicate
|
C |
first(int numRows) |
C |
inRange(int start,
int end)
Returns a column containing the rows in this column beginning with start inclusive, and ending
with end exclusive
|
C |
last(int numRows) |
C |
map(Function<? super T,? extends T> fun)
Maps the function across all rows, appending the results to a new Column of the same type
|
C |
max(Column<T> other)
Returns a column containing the element-wise min between this column and other column
|
C |
min(Column<T> other)
Returns a column containing the element-wise min between this column and other column
|
String |
name()
Returns the column's name.
|
C |
sampleN(int n)
Returns a column containing a random sample of the values in this column
|
C |
sampleX(double proportion)
Returns a table consisting of randomly selected values from this column.
|
C |
set(Selection condition,
Column<T> other)
Updates this column where values matching the selection are replaced with the corresponding
value from the given column
|
C |
set(Selection rowSelection,
T newValue)
Conditionally update this column, replacing current values with newValue for all rows where the
current value matches the selection criteria
|
C |
setName(String name)
Sets the columns name to the given string
|
C |
sorted(Comparator<? super T> comp)
Returns a new Column of the same type sorted according to the provided Comparator
|
C |
subset(int[] rows) |
String |
toString() |
ColumnType |
type()
Returns this column's ColumnType
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitallMatch, anyMatch, append, append, append, appendCell, appendCell, appendMissing, appendObj, asBytes, asList, asObjectArray, byteSize, clear, columnWidth, contains, copy, count, count, countMissing, countUnique, emptyCopy, get, getString, getUnformattedString, interpolate, isEmpty, isMissing, isMissing, isNotMissing, lag, lead, map, mapInto, max, min, noneMatch, print, reduce, reduce, removeMissing, rolling, rowComparator, set, set, set, setMissing, setMissingTo, size, sortAscending, sortDescending, summary, title, unique, whereforEach, iterator, spliteratorcompare, comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongpublic static final int DEFAULT_ARRAY_SIZE
public AbstractColumn(ColumnType type, String name)
public C setName(String name)
Columnpublic ColumnType type()
Columntype in interface Column<T>ColumnTypepublic abstract Column<T> emptyCopy()
Columnpublic C filter(Predicate<? super T> test)
Columnpublic C sorted(Comparator<? super T> comp)
Columnpublic C map(Function<? super T,? extends T> fun)
Columnpublic C min(Column<T> other)
ColumnTODO(lwhite) Override in column subtypes for better performance
public C max(Column<T> other)
ColumnTODO(lwhite) Override in column subtypes for better performance
public C set(Selection condition, Column<T> other)
Columnpublic C set(Selection rowSelection, T newValue)
Columnpublic C sampleN(int n)
Columnpublic C sampleX(double proportion)
Columnpublic C inRange(int start, int end)
Columnpublic StringColumn asStringColumn()
ColumnasStringColumn in interface Column<T>StringColumn built using the column Column.getUnformattedString(int) methodCopyright © 2020. All rights reserved.