i have an excel spread sheet of forex market prices. i'm trying to convert a 5 minute chart into a 15 minute chart. i don't understand how i get the macro to run down the entire column. i have four numbers, the open, the high, the low, and the close. to get the open i just transfer the open of the first 5 minute block over, skip two cells then do it again, like this:
ActiveCell.FormulaR1C1 = "=RC[-7]"
ActiveCell.Offset(2, 0).Range("A1").Select
but then i can't figure out how to get that to keep going throughout the entire column. for the high, i would just do =max(c1:c3), then =max(c4:c6) but i also can't figure out how to repeat that for the whole column.
i then have one other problem. for some odd reason the market doesn't close at 9:59:59 on friday but closes on 10:00:59, so there's one section that is actually a 16 minute block, or there is an orphan minute. i have to make an exception and include that 10:00:00 - 10:00:59 to the previous 15 minute block, but to do that i need to make an exception. i was thinking something like
if one block with 10:00 is followed by another block with 0:00 because that's when the market opens on monday, then combine the 10:00 block with the block before it, but i don't know how to write that code.
here's a spreadsheet (i don't see anywhere here for uploading attachments)
http://spreadsheets.google.com/ccc?k...4UURjTXc&hl=en
Bookmarks