powered by
Subset a numeric series
dsct_drop( x, from = -Inf, to = Inf, ..., include_from = TRUE, include_to = TRUE )dsct_keep( x, from = -Inf, to = Inf, ..., include_from = TRUE, include_to = TRUE )
dsct_keep( x, from = -Inf, to = Inf, ..., include_from = TRUE, include_to = TRUE )
A numeric series representing the subset of discrete values within the specified range.
Numeric series (numeric vector or object of class "discretes").
numeric
"discretes"
Numeric values defining the range to keep; single numerics with from <= to.
from <= to
Reserved for future extensions; must be empty.
Logical values indicating whether the from and to values should be included in the kept range; single logicals.
from
to
x <- integers(from = -3) dsct_keep(x, from = -1.5, to = 2.5) dsct_keep(x, to = 2)
Run the code above in your browser using DataLab