Message-ID: <0CEDD33E-413D-46A1-A601-A8B84B0FBD35@me.com>
Date: 2010-01-01T16:28:19Z
From: donahchoo at me.com
Subject: need more help.... Re: iterating over a data frame the R way?
In-Reply-To: <7642E99C-75AD-4815-92C0-7EBD9779D968@me.com>
Hum. data.frame was left off. Trying again...
-------------- next part --------------
On Jan 1, 2010, at 10:20 AM, donahchoo at me.com wrote:
> Okay, I don't know if I'm blocking because of my other programming
> language experience of if I'm just being dense.
>
> I have a data.frame with high,open,low,last,day, and start_time time
> columns. What I want to do is get all the rows with the same day
> and process each of those columns. If I was able to run a query
> against the data.frame I would be want something like:
>
> result = all the rows where the day is equal to 2007-12-05
>
> Then I would want get max(result["high"]), min(result["low"])
>
> How do I do this? I tired sqldf, but its complaining about
> libtcl0.5.8 not being found. I'm on OS X 10.5.8 and haven't yet
> tired to install a new version of tcl in /usr/local.
>
> Here's the dataframe:
>
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.