`ordered_result` argument in cut.integer and cut.ordered

#11 · open · 1 comments

View on GitHub ↗

lorenzwalthert

Currently, the two cut methods for integer and ordered inherit from the default method regarding whether or not the output should be an ordered factor. In the helpfile, it is stated that > Logical: should the result be an ordered factor? This seems to be a strange behavior since by nature, we are dealing with an sequence of ordered values, otherwise cut could not have been applied. Hence, I suggest to change the default to `TRUE` and document this in the help file under details.

Comments

jonmcalder

Yeah I don't really understand that default either so what you're suggesting makes sense, but at the same time I'm not sure what the ramifications of changing it might be (e.g. for other functions calling cut and expecting non-ordered output). http://r.789695.n4.nabble.com/R-Why-the-factor-levels-returned-by-cut-are-not-ordered-td813586.html