How do you sort a two-dimensional object? By modulus? Lexicographic?
Same way base R does it. From ?order:
?order
Complex values are sorted first by the real part, then the imaginary part.
strange to me to say 0 + 300000000000i < 1 + i, but as long as it's base-consistent.
0 + 300000000000i < 1 + i
Closes #1703 -- forderv handles complex input
Activity
MichaelChirico commentedon May 13, 2016
How do you sort a two-dimensional object? By modulus? Lexicographic?
arunsrinivasan commentedon May 19, 2016
Same way base R does it. From
?order:MichaelChirico commentedon May 19, 2016
strange to me to say
0 + 300000000000i < 1 + i, but as long as it's base-consistent.Closes #1703 -- forderv handles complex input