On Wed, 29 Nov 2006, Petr Pikal wrote:
On 29 Nov 2006 at 12:08, Peter Dalgaard wrote:
Date sent:Wed, 29 Nov 2006 12:08:21 +0100
From: Peter Dalgaard [EMAIL PROTECTED]
To: Wolfram Fischer [EMAIL PROTECTED]
Copies to:
What is the reason, that the levels of the factor
returned by cut() are not marked as ordered levels?
is.ordered( cut( breaks=3, sample(10 ) ) )
FALSE
help(factor)
...
If 'ordered' is 'TRUE', the factor levels are assumed to be ordered.
...
Wolfram
Hi
it is not stated that the cut shall return ordered factor. If you
want you can use
ordered(cut( breaks=3, sample(10 ) ))
or modify code for cut.default to accept ordered switch.
HTH
Petr
On 29 Nov 2006 at 9:59, Wolfram Fischer wrote:
Date sent: Wed, 29 Nov 2006 09:59:36
Wolfram Fischer wrote:
What is the reason, that the levels of the factor
returned by cut() are not marked as ordered levels?
I don't know, but you can always make it ordered with
ordered(cut(breaks = 3, sample(10)))
help(factor)
...
If 'ordered' is 'TRUE', the factor levels are
Wolfram Fischer wrote:
What is the reason, that the levels of the factor
returned by cut() are not marked as ordered levels?
is.ordered( cut( breaks=3, sample(10 ) ) )
FALSE
It would arguably be the Right Thing, but there would be complications
in modeling, where ordered
On 29 Nov 2006 at 12:08, Peter Dalgaard wrote:
Date sent: Wed, 29 Nov 2006 12:08:21 +0100
From: Peter Dalgaard [EMAIL PROTECTED]
To: Wolfram Fischer [EMAIL PROTECTED]
Copies to: r-help@stat.math.ethz.ch
Subject:Re: