Crunch Expressions, i.e. CrunchExpr
and CrunchLogicalExpr
,
encapsulate derivations of Crunch variables, which are only evaluated when
passed to a function like as.vector
. They allow you to compose
functional expressions of variables and evaluate them against the server
only when appropriate.
# S4 method for CrunchExpr
!(x)# S4 method for CategoricalVariable,character
%in%(x, table)
# S4 method for CategoricalVariable,factor
%in%(x, table)
# S4 method for TextVariable,character
%in%(x, table)
# S4 method for NumericVariable,numeric
%in%(x, table)
# S4 method for DatetimeVariable,Date
%in%(x, table)
# S4 method for DatetimeVariable,POSIXt
%in%(x, table)
# S4 method for DatetimeVariable,character
%in%(x, table)
# S4 method for CategoricalVariable,numeric
%in%(x, table)
# S4 method for CategoricalVariable,character
==(e1, e2)
# S4 method for CategoricalVariable,factor
==(e1, e2)
# S4 method for CategoricalVariable,character
!=(e1, e2)
# S4 method for CategoricalVariable,factor
!=(e1, e2)
# S4 method for CrunchVariable
is.na(x)
bin(x)
rollup(x, resolution = rollupResolution(x))
an input
For %in%
. See base::match()
an input
an input
For rollup
. Either NULL
or a character in
c("Y", "Q", "M", "W", "D", "h", "m", "s", "ms") indicating the unit of
time at which a Datetime variable should be aggregated. If NULL
,
the server will determine an appropriate resolution based on the range of
the data.
Most functions return a CrunchExpr or CrunchLogicalExpr.
as.vector
returns an R vector.