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.

ticks on market direction change and history
 Post subject: ticks on market direction change and history Post rating: 0   New post Posted: Thu 05 Sep, 2013, 09:13 

User rating: 0
Joined: Sat 08 Jun, 2013, 12:05
Posts: 71
Location: FranceFrance
It seems to behave like expected, but I'd like to make sure:
when fetching the previous on direction change tick with history.getTick(instrument, 1) we get the same ITick that was processed one event ago
so the history API is behaving differently for the different backtest modes? in this cases it returns only those ticks and not absolute ticks
thanks


 
 Post subject: Re: ticks on market direction change and history Post rating: 0   New post Posted: Thu 05 Sep, 2013, 09:28 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
Please provide an example strategy which replicates the case. Describe the launch conditions. If you use Historical Tester please do provide its settings.


 
 Post subject: Re: ticks on market direction change and history Post rating: 0   New post Posted: Thu 05 Sep, 2013, 11:59 

User rating: 0
Joined: Sat 08 Jun, 2013, 12:05
Posts: 71
Location: FranceFrance
well directly using the jforex remote historrical tester, with "process ticks on a market direction change"

and btw:
ITick prevTick;

public void onTick(Instrument instrument, ITick tick) throws JFException {
        print(prevTick== history.getTick(instrument, 1));//they are equal
        prevTick = tick;
}


 
 Post subject: Re: ticks on market direction change and history Post rating: 0   New post Posted: Thu 05 Sep, 2013, 12:10 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
Did you check the strategy with both of those historical tester settings? Did it work as expected?


 
 Post subject: Re: ticks on market direction change and history Post rating: 0   New post Posted: Thu 05 Sep, 2013, 15:28 

User rating: 0
Joined: Sat 08 Jun, 2013, 12:05
Posts: 71
Location: FranceFrance
yes it works as expected, they are equal.
though it would be good to be able to call history with a parameter of choice (all ticks (DataLoadingMethod.ALL_TICKS), on larket change ticks, ..)


 
 Post subject: Re: ticks on market direction change and history Post rating: 0   New post Posted: Fri 06 Sep, 2013, 15:19 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
lil wrote:
though it would be good to be able to call history with a parameter of choice (all ticks (DataLoadingMethod.ALL_TICKS), on larket change ticks, ..)
Optimization is not the job of API. Why would you need something like this?


 

Jump to:  

  © 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