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.

linearRegAngle ind
 Post subject: linearRegAngle ind Post rating: 0   New post Posted: Mon 02 Jul, 2012, 17:40 

User rating: 0
Joined: Thu 03 Nov, 2011, 21:46
Posts: 68
Location: Russian Federation,
Hello support!

please help,
I want to know that linAnPrev value was green. and new linAn red.
please see screenshot:

double linAn = indicators.linearRegAngle(currentInstrument, period,OfferSide.BID,IIndicators.AppliedPrice.CLOSE,14,0);
double linAnPrev = indicators.linearRegAngle(currentInstrument, period,OfferSide.BID,IIndicators.AppliedPrice.CLOSE,14,1);

example:
if ( linAnPrev (Green) && linAn(Red) ) {
signSell = true;

if ( linAnPrev (Green) && linAn(Green) ) {
signSell = false;

thank You


Attachments:
lin1.gif [37.2 KiB]
Downloaded 286 times
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control on their content. Anyone accessing this webpage and downloading or otherwise making use of any document, data or information found on this webpage shall do it on his/her own risks without any recourse against Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from the use and/or reliance on any document, data or information found on this webpage.
 
 Post subject: Re: linearRegAngle ind Post rating: 0   New post Posted: Tue 03 Jul, 2012, 08:49 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
See the onBar method in:
https://www.dukascopy.com/wiki/#Create_Alert/Play_sound_on_indicator_trend_change
Change the optional input parameters and indicator from t3 to linearRegAngle.


 
 Post subject: Re: linearRegAngle ind Post rating: 0   New post Posted: Tue 03 Jul, 2012, 13:26 

User rating: 0
Joined: Thu 03 Nov, 2011, 21:46
Posts: 68
Location: Russian Federation,
API Support wrote:
See the onBar method in:
https://www.dukascopy.com/wiki/#Create_Alert/Play_sound_on_indicator_trend_change
Change the optional input parameters and indicator from t3 to linearRegAngle.


hi,
I make test this variant:

private static int LAST = 2;
private static int PREV = 1;
private static int SCND_TO_LAST = 0;
double[] t = indicators.linearRegAngle(Instrument.EURUSD, Period.ONE_HOUR,OfferSide.BID,IIndicators.AppliedPrice.CLOSE, 14, filter,3,bidBar.getTime(), 0);

if( t[PREV] > t[LAST] && t[SCND_TO_LAST] < t[PREV] ){
sellSign= true;

if( t[PREV] < t[LAST] && t[SCND_TO_LAST] > t[PREV]){
buySign = true;

But not open position:
please see screenshot


it defines color?

I want to have signal from change color
it is possible ?

thank you


Attachments:
lin3.gif [24.5 KiB]
Downloaded 314 times
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control on their content. Anyone accessing this webpage and downloading or otherwise making use of any document, data or information found on this webpage shall do it on his/her own risks without any recourse against Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from the use and/or reliance on any document, data or information found on this webpage.
 
 Post subject: Re: linearRegAngle ind Post rating: 0   New post Posted: Tue 03 Jul, 2012, 13:46 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
please provide full example strategy.


 

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