The suggestions from others to use lattice's xyplot, or ggplot2 are good.
If you want an explicit loop you can do something like:
for ( nm in unique(mydat$Name) ) {
with( subset( mydf, Name==nm) ,
{
plot(Time, Value, title=nm)
readline('CR to continue ')
}
)
}
At 5:19
On Mon, Sep 14, 2009 at 5:19 AM, Schalk Heunis
wrote:
> Chris
> try this (assume your dataset is in a dataframe called ms):
> library(lattice)
> xyplot(Value~Time|Name,data = ms)
>
> HTH
> Schalk
>
>
>
> On Mon, Sep 14, 2009 at 2:19 AM, Chris Li wrote:
>
>>
>> Hi all,
>>
>> I am new to R and I hav
Chris Li wrote:
>
> Hi all,
>
> I am new to R and I have got a question in regards to factors.
>
> Say I have a simple dataset like the following:
>
> Name Time Value
> a 1:00 1.25
> a 2:00 1.26
> b 1:00 1.29
> b 2:00 1.28
> c 1:0
Hi all,
I am new to R and I have got a question in regards to factors.
Say I have a simple dataset like the following:
Name Time Value
a 1:00 1.25
a 2:00 1.26
b 1:00 1.29
b 2:00 1.28
c 1:00 1.21
c 1:30 1.20
c
4 matches
Mail list logo