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.

Filtering weekend flat from inside of user indicator
 Post subject: Filtering weekend flat from inside of user indicator Post rating: 0   New post Posted: Wed 03 Aug, 2011, 09:08 

User rating: 0
Joined: Wed 03 Aug, 2011, 08:52
Posts: 2
Location: RU
Hello.
I'm developing an indicator, and have such problem:
My indicator calculates bars that are on the weekend (for example hour bar at 21.00 july 29 2011 that has non zero volume but market should be closed that time) and this destroys indicator logic.
I want to filter indicator's input like that is realized in history.getBars, but there is no access to history through IIndicatorContext.getHistory().
How can i do that?

Thanks for your help.


 
 Post subject: Re: Filtering weekend flat from inside of user indicator Post rating: 0   New post Posted: Thu 04 Aug, 2011, 10:34 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
Have you considered applying Filter.NO_FILTER to InputParameterInfo? For example:
InputParameterInfo inputASK = new InputParameterInfo("PriceASK", InputParameterInfo.Type.BAR);
inputASK.setOfferSide(OfferSide.ASK);
inputASK.setFilter(Filter.NO_FILTER);            
inputParameterInfos = new InputParameterInfo[] {  inputASK  };


 

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