tabsdata.tableframe.expr.expr
deprecated_category | |
ErrorCode | |
Expr | |
Expr.abs | Return the abso lute value of the expression. |
Expr.add | Equivalent to the + operator. |
Expr.alias | Set the name for a column or expression. |
Expr.and_ | Bitwise and operator with the given expressions. |
Expr.arccos | Calculate the inverse cosine of the element value. |
Expr.arccosh | Calculate the inverse hyperbolic cosine of the element value. |
Expr.arcsin | Calculate the inverse sine of the element value. |
Expr.arcsinh | Calculate the inverse hyperbolic sine of the element value. |
Expr.arctan | Calculate the inverse tangent of the element value. |
Expr.arctanh | Calculate the inverse hyperbolic tangent of the element value. |
Expr.cast | Cast a value to d different type. |
Expr.cbrt | Calculate the cub root of the element value. |
Expr.ceil | Round up the expression to the next integer value. |
Expr.clip | For element values outside the lower and upper bounds, lower values are replaced with the lower bound and upper values with the upper bound. |
Expr.cos | Calculate the cosine of the element value. |
Expr.cosh | Calculate the hyperbolic cosine of the element value. |
Expr.cot | Calculate the cotangent of the element value. |
Expr.count | Aggregation operation that counts the non null values of the given column in the group. |
Expr.degrees | Convert a radian value to degrees |
Expr.diff | Compute the difference between an element value and the element value of the specified relative row. |
Expr.eq | Compare if 2 expressions are equal, equivalent to expr == other. |
Expr.eq_missing | Compare if 2 expressions are equal an, equivalent to expr == other. |
Expr.exp | Calculate the exponential of the element value. |
Expr.fill_nan | Replace NaN values with the given value. |
Expr.fill_null | Replace null values with the given value. |
Expr.filter | Apply a filter predicate to an expression. |
Expr.first | Get the first element. |
Expr.floor | Round down the expression to the previous integer value. |
Expr.floordiv | Calculate the floor on the division. |
Expr.ge | Greater or equal operator. |
Expr.gt | Greater than operator. |
Expr.hash | Compute the hash of an element value. |
Expr.is_between | If an expression is between the given bounds. |
Expr.is_finite | If an element value is finite. |
Expr.is_in | If an element value is in the given collection. |
Expr.is_infinite | If an element value is infinite. |
Expr.is_nan | If an element value is NaN. |
Expr.is_not_nan | If an element value is not NaN. |
Expr.is_not_null | If an element value is not null (None). |
Expr.is_null | If an element value is null (None). |
Expr.is_unique | If an element value is unique for all values in the column. |
Expr.last | Get the last element. |
Expr.le | Less or equal operator. |
Expr.len | Aggregation operation that counts the rows in the group. |
Expr.log | Calculate the logarithm to the given base. |
Expr.log10 | Calculate the logarithm base 10. |
Expr.log1p | Calculate the natural logarithm plus one. |
Expr.lt | Less than operator. |
Expr.max | Aggregation operation that finds the maximum value in the group. |
Expr.mean | Aggregation operation that finds the mean of the values in the group. |
Expr.median | Aggregation operation that finds the median of the values in the group. |
Expr.min | Aggregation operation that finds the minimum value in the group. |
Expr.mod | Modulus operator. |
Expr.mul | Multiplication operator. |
Expr.n_unique | Aggregation operation that counts the unique values of the given column in the group. |
Expr.ne | Compare if 2 expressions are not equal, equivalent to expr != other. |
Expr.ne_missing | Compare if 2 expressions are not equal an, equivalent to expr != other. |
Expr.neg | Unary minus operator. |
Expr.not_ | Negate a boolean expression. |
Expr.or_ | Bitwise or operator with the given expressions. |
Expr.pow | Exponentiation operator. |
Expr.radians | Convert a degree value to radians |
Expr.rank | Compute the rank of the element values. |
Expr.reinterpret | Reinterpret the 64bit element values (i64 or u64) as a signed/unsigned integers. |
Expr.round | Round floating point element values. |
Expr.round_sig_figs | Round floating point element values to the specified significant figures. |
Expr.shrink_dtype | Cast down a column to the smallest type that can hold the element values. |
Expr.sign | Calculate the sign of element values. |
Expr.sin | Calculate the sine of the element value. |
Expr.sinh | Calculate the hyperbolic sine of the element value. |
Expr.slice | Compute a slice of the TableFrame for the specified columns. |
Expr.sqrt | Calculate the square root of the element value. |
Expr.sub | Equivalent to the - operator. |
Expr.sum | Aggregation operation that sums the values in the group. |
Expr.tan | Calculate the tangent of the element value. |
Expr.tanh | Calculate the hyperbolic tangent of the element value. |
Expr.truediv | Equivalent to the float / operator. |
Expr.xor | Bitwise xor operator with the given expression. |
expr_resolves_to_multiple_outputs | |
TableFrameError | Exception raised when handling a TableFrame. |
deprecated_category
functionView source ↗
def deprecated_category(
reason: str,
replacement: str | None = None,
since: str | None = None,
) -> type[TabsdataDeprecatedWarning]
ErrorCode
classView source ↗
class ErrorCode(*args, **kwds)
Bases: Enum
Expr
classView source ↗
class Expr(expr: Expr | Expr)
property
dtExprDateTimeNameSpace:categories: type_casting
Return an object namespace with all date-time methods for a date-time value.
property
strExprStringNameSpace:categories: type_casting
Return an object namespace with all string methods for a string value.
abs()add()alias()and_()arccos()arccosh()arcsin()arcsinh()arctan()arctanh()cast()cbrt()ceil()clip()cos()cosh()cot()count()degrees()diff()eq()eq_missing()exp()fill_nan()fill_null()filter()first()floor()ge()gt()hash()is_between()is_finite()is_in()is_infinite()is_nan()is_not_nan()is_not_null()is_null()is_unique()last()le()len()log()log10()log1p()lt()max()mean()median()min()mod()mul()n_unique()ne()ne_missing()neg()not_()or_()pow()radians()rank()reinterpret()round()round_sig_figs()shrink_dtype()sign()sin()sinh()slice()sqrt()sub()sum()tan()tanh()truediv()xor()
method
View source ↗floordivdef floordiv(other: Any) -> Expr
Calculate the floor on the division.
Parameters:
parameter
otherThe value to divide by.
Example:
>>> import tabsdata as td
>>>
>>> tf: td.TableFrame ...
>>>
>>> tf = tf.select(td.col("temp"), td.col("temp").floordiv(2)
>>> .alias("floordiv"))
>>>
┌──────┬──────────┐
│ temp ┆ floordiv │
│ --- ┆ ------- │
│ f64 ┆ i64 │
╞══════╪══════════╡
│ 2.5 ┆ 1 │
│ 1.4 ┆ 0 │
└──────┴──────────┘
expr_resolves_to_multiple_outputs
functionView source ↗
def expr_resolves_to_multiple_outputs(expr: Expr) -> bool
TableFrameError
classView source ↗
class TableFrameError(error_code: ErrorCode, *args)
Bases: TabsDataException
Exception raised when handling a TableFrame.
property
error_codeErrorCode