EXPAND ALL
  • Home

modulo

Calculates the remainder of dividing the first argument by the second argument. Same results as the C++ modulo operator. Accessible using the % syntax.

Returns: INT64

The remainder of dividing `a` by `n`

Arguments

VariableTypeDescription
aTIME64NS / INT64The dividend.
nINT64 / TIME64NSThe divisor.

Examples:

# Implicit call.
df.duration_mod_5s = df.duration % px.seconds(5)
# Explicit call.
df.duration_mod_5s = px.modulo(df.duration, px.seconds(5))
This site uses cookies to provide you with a better user experience. By using Pixie, you consent to our use of cookies.