In chronological price list Takayasu 1 ● Date Time High Low Low 2 ● Date Time High Low Low 3 ● Date Time High Low Low 4 ● Date Time High Low Low 5
1 is the oldest, 2,3,4 ... is the high and low price data every minute, can you teach me the programming method when you want to do the following?
① First, the high and low prices of 1 are defined as high 1 and low 1.
(2) High low price <high 1 and low price <low 1 are defined as high 2 and low 2 in chronological order.
③-1) After ② appears If a high low price such as high 1> high> low 2, low 2> low appears, the high price is "ha", the low price is "ni", the high 1 is "i", and the low 2 is "ro". Define and extract the date and time (or line number of the original data) and value corresponding to "i", "ro", "ha", and "ni" on another sheet (★)
For example
"I" "ro" "ha" "ni" Date Time High 1 (Number) Year Month Day Time Low 2 (Number) Year Month Day Time High Price (Number) Year Month Day Time Low Price (Number)
③-2) After ② appears If a high low price appears where high price> high 1> low price 2> low price, define the high price as "i" and define it as "i". Extract the date and time and high price (number) of "I" to a sheet (■) different from the sheet created in (3) -1) above.
④ After ③-1) and ③-2) above, return to ①, this time Skip the line 1 and define the high low price of 2 as high 1 and low 1 first, follow the process of ② to ③, and go to the sheet (★) (■) created in ③-1) and ③-2). I will add
⑤ Loop the process from ① to ④
And as a future prospect, I would like to make verification materials by changing the conditions for ② to ③ based on the molds ① to ⑤.
Recommended Posts