Frame / column operations #27
Reference in New Issue
Block a user
Delete Branch "feat/simple-frame-ops"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This PR mainly adds method registries for frames, columns, and their group-by counterparts. It implements a number of methods and attributes, including arithmetic operations (+, -, *, /, etc.), comparisons (>, <, >=, <=, etc.) and aggregation methods (min, max, mean, median, etc.). The type checker will try and infer the resulting type, and fallback to a top type if it cannot properly express it. For example,
ColumnType[int].mean()results inColumnType[Any], whilstColumnType[int].median()results inColumn[int]because the median is necessarily one of the column's values.Where possible, inference is delegated to the columns / inner types.
Element-wise operations also generate an assertion to ensure that the two operands have the same number of elements.