| h_count_cumulative {tern} | R Documentation | 
Helper function for s_count_cumulative()
Description
Helper function to calculate count and fraction of x values in the lower or upper tail given a threshold.
Usage
h_count_cumulative(
  x,
  threshold,
  lower_tail = TRUE,
  include_eq = TRUE,
  na.rm = TRUE,
  .N_col
)
Arguments
x | 
 (  | 
threshold | 
 (  | 
lower_tail | 
 (  | 
include_eq | 
 (  | 
na.rm | 
 (  | 
.N_col | 
 (  | 
Value
A named vector with items:
-  
count: the count of values less than, less or equal to, greater than, or greater or equal to a threshold of user specification. -  
fraction: the fraction of the count. 
See Also
Examples
set.seed(1, kind = "Mersenne-Twister")
x <- c(sample(1:10, 10), NA)
.N_col <- length(x)
h_count_cumulative(x, 5, .N_col = .N_col)
h_count_cumulative(x, 5, lower_tail = FALSE, include_eq = FALSE, na.rm = FALSE, .N_col = .N_col)
h_count_cumulative(x, 0, lower_tail = FALSE, .N_col = .N_col)
h_count_cumulative(x, 100, lower_tail = FALSE, .N_col = .N_col)
[Package tern version 0.9.5 Index]