I'm new to coding, so I'm not even sure where to start. I have a table with prices by day. I want to start with the first day, 1/1/2009 and step through each record in date order. I want to set a flag when the price goes below 11.25, and then count how many days it takes to go above 11.75. Then, reset the flag and count how many days it takes to fall back below 11.25. The end result is to have how many times the price fell below 11.25, and how many times it rises above 11.75 and the average time between each peak and valley. Looking at a graph, the solution looks easy, turning it into code that works is where I need help. I appreciate any responses.
Jeff
Jeff