Dukascopy
 
 
Wiki JStore Search Login

Attention! Read the forum rules carefully before posting a topic.

    Try to find an answer in Wiki before asking a question.
    Submit programming questions in this forum only.
    Off topics are strictly forbidden.

Any topics which do not satisfy these rules will be deleted.

Need help with onBar method using Renko feed
 Post subject: Need help with onBar method using Renko feed Post rating: 0   New post Posted: Tue 04 Sep, 2012, 06:48 
User avatar

User rating: 0
Joined: Tue 04 Sep, 2012, 06:35
Posts: 11
Location: Hungary,
Hi all!

I need a bit of help creating a most likely quite simple code.

I would like to make a strategy which operates on a certain renko chart and opens a new position on every new candle.

From what I figured out, if one wishes to work with renko charts, should subscribe to a renko feed as described in the Wiki section, and orders executed on every bar should be placed in the onBar method.

What I'm asking for, is the simplest implementation of IStrategy interface which places a new buy@market order on every new renko candle (for the sake of simplicity let the pair be EURUSD, and the brick size 5 pips).

Your help is very much appreciated!

Thank you in advance.


 
 Post subject: Re: Need help with onBar method using Renko feed Post rating: 0   New post Posted: Tue 04 Sep, 2012, 09:30 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
  1. Take the example from https://www.dukascopy.com/wiki/#Chart_feeds/Subscribe_to_a_feed and change the range bar feed to renko feed from the table https://www.dukascopy.com/wiki/#Chart_feeds/Feed_types
  2. Insert the code from the https://www.dukascopy.com/wiki/#Set_Market_Order in your IFeedListener.onFeedData method.
Let us know if you encounter any problems.


 

Jump to:  

cron
  © 1998-2025 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com