detection of a 2 point down trend touch line

Discussion in 'Strategy Development' started by hanhao, Jun 19, 2007.

  1. hanhao

    hanhao

    detection of a 2 point down trend touch line

    Hi fellow technical traders. i am trying to code an algorithm for the detection of a 2 point down trend touch in the last 6 months or so and automatically drawing the trendline. A 2 point down trend touch line is where the stock is trending down and the trendline is drawn across 2 of it's most highest more protruding highs. perhaps a picture would be better to explain this. The link for this picture is http://img501.imageshack.us/img501/7889/2pointgm0.jpg

    [​IMG]

    is there any exsisting indicator to help me with this? if not, can anyone suggest an algorithm to get this other than drawing the trendline mannually? i am currently coding in metastocks

    many thanks! :)
    hanhao