Dieter Menne wrote:
Peter Dalgaard wrote:
d <- data.frame(f=c("rare", "medium","well-done"))
#To get the cast in order of appearance, this can be used:
> d$f <- factor(d$f, levels=unique(d$f))
> d$f
[1] rare mediumwell-done
Levels: rare medium well-done
.. which caused some head
Thank you very much,
You solved my problem.
On Mon, Feb 22, 2010 at 12:42 AM, Peter Dalgaard
wrote:
> Or Duek wrote:
>
>> Ok,
>> It seems that the problem lays in the order (as Ista mentioned),
>> But, when I ask R to order it he chooses to order it by size and not by
>> the
>> specific order I m
Peter Dalgaard wrote:
>
> d <- data.frame(f=c("rare", "medium","well-done"))
> #To get the cast in order of appearance, this can be used:
>
> > d$f <- factor(d$f, levels=unique(d$f))
> > d$f
> [1] rare mediumwell-done
> Levels: rare medium well-done
>
>
.. which caused some head-s
Or Duek wrote:
Ok,
It seems that the problem lays in the order (as Ista mentioned),
But, when I ask R to order it he chooses to order it by size and not by the
specific order I mentioned when I built the vector.
Is it possible to tell him to keep the order as mentioned?
Thank you.
You're still
Perhaps this example will help.
x <- factor(c('b','a','d'), levels=c('a','d','b'))
y <- 1:3
plot(x,y)
And compare with
z <- factor(c('b','a','d'))
plot(z,y)
In the first, the plot is in the order that I chose. In the second it
is in the order that R chose -- and R chose it according
Ok,
It seems that the problem lays in the order (as Ista mentioned),
But, when I ask R to order it he chooses to order it by size and not by the
specific order I mentioned when I built the vector.
Is it possible to tell him to keep the order as mentioned?
Thank you.
On Sun, Feb 21, 2010 at 6:16 P
Hi Or,
I can't know for sure what your problem is without an example, but the
first thing I would do is check to make sure that your labels are
stored as an ordered factor (and that the order is correct). See
?factor for details.
Best,
Ista
On Sun, Feb 21, 2010 at 10:57 AM, Or Duek wrote:
> Hi,
Hi,
I created a simple data frame with one factor and one numerical variable.
The factor was actually a vector of names of techniques to trimm reaction
time data.
I want to create a plot that shows the value of F test for every trimming
method.
So the data frame has its trim factor (who has those l
8 matches
Mail list logo