Jump to content
Tom Next - Daytrading Community

Dataseries an einen Indikator übergeben


Eddy

Recommended Posts

Ich möchte in einer Strategie zwei Timeframes nutzten, wobei jeder Timeframe einem Indikator zugeordnet werden soll.

 

Ich bekomme das nicht hin. Hier ein kurzes Beispiel:

 

Der Indikator heißt I123. dataseries_2 soll die 60 Min. Periode sein. Hierfür habe ich Inputs[0] bzw. Inputs[1] probiert.

Der Chart ist ein 10 Min. Chart.

 

protected override void Initialize()
{
  Add(PeriodType.Minute, 60); 
  I123 i123A = I123(1);
  I123 i123B = I123(dataseries_2, 2);
...

 

Im Indikator drucke ich die Periode mit

Print ("TF: " + tf + " / BarsPeriod.BasePeriodType: " + BarsPeriod.BasePeriodType 
+ " / BarsPeriod.Value: " + BarsPeriod.Value);

 

Inputs[0] und Inputs[1] als Parameter liefern die Ausgabe:

 

TF: 1 / BarsPeriod.BasePeriodType: Minute / BarsPeriod.Value: 10
TF: 2 / BarsPeriod.BasePeriodType: Minute / BarsPeriod.Value: 10

 

Hat jemand eine Idee wie man das Problem löst?

 

Eddy

Edited by Eddy
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...