How to use indicator in an strategy

Forums ProRealTime English forum ProOrder support How to use indicator in an strategy

Viewing 6 posts - 1 through 6 (of 6 total)
  • #53401

    Hi colleagues,

    I have been checking the PRT probuilder manual, and I need help to understand how to use an indicator into an strategy. There are many indicators that display pivotal points as arrows (x1,y1) and ellipses (x1, y1, x2, y2). It is very interesting for automatic trading to take this points (arrows) to place orders.

    My question is how can I program a buy or sell order in reference to these points?

    I have checked the blogs but I couldn’t find any reference about this. I would appreciate any links to this kind of information, or a brief example of a coded order.

     

    Thanks in advance for any help,

    Juan

    #53406

    Just copy the indicator the code in your code. Then you have the parameters in the variables and can use it to generate orders.

    #53408

    Thanks Despair,

    I have been trying to convert an indicator into an strategy, but when it comes to formulate the orders, I have to eliminate the drawing objects, and thus, I eliminate some of the conditions that create those drawings.

    So I thought if would be easier to use the complete indicator and then the strategy “calling” the indicator, but the problem is what do you put into the buying order.

    IF (x1,y1) THEN

    BUY…

    ENDIF

    #53415

    You must remove all drawing commands. The x-coordinate is usually the barindex and the y-coordinate is where you want to place your order (close crosses over Y1 or something like this).

    2 users thanked author for this post.
    #53424

    After removing all graphic command, as Despair said, you may use the conditions that caused the command to be executed as your conditions in your strategy. Example (taken from a Candlestick pattern recognizer):

    when embedded into your strategy will look like this:

     

    3 users thanked author for this post.
    #53442

    Hi guys @Despair,@Roberto,

    Thanks so much for your help,

    That is what I did. I removed all graphics command from the code and replaced them with the order. If it said DRAWARROWUP I went LONG and such…

    But in the case of the Indicator WILLIAMSHIGHANDLOW, removing the command DRAWELLIPSE, which it was a swing pivotal point of importance, disrupted the indicator and screwed the strategy code, since (x1,y1,x2,y2) was part of the code. But, knowing it is the way, I will do it that way.

    Thanks so much for your help,

    Juan

Viewing 6 posts - 1 through 6 (of 6 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login