[R] Improvement: function cut

Leonard Mada |eo@m@d@ @end|ng |rom @yon|c@eu
Fri Sep 17 23:44:58 CEST 2021


Hello List members,


the following improvements would be useful for function cut (and .bincode):


1.) Argument: Include extremes
extremes = TRUE
if(right == FALSE) {
    # include also right for last interval;
} else {
    # include also left for first interval;
}


2.) Argument: warn = TRUE

Warn if any values are not included in the intervals.


Motivation:
- reduce risk of errors when using function cut();


Sincerely,


Leonard



More information about the R-help mailing list