log2 - Calculate log to base 2
log2
is a shorthand for computing log(2, number)
. It calculates the log, to base 2, for a given value.
Syntax
Arguments
Name | Type | Required | Description |
---|---|---|---|
number | number | true | The value whose logarithm we wish to find |
Example - Basic usage
The log2
command is simple and intuitive to use:
This command will create a new field, log_field
which is equal to the log to base 2 of some_value
.
NOTE: some_value
MUST be a numerical type.
Theme
Light