Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Debug indicator in strategy
Collapse
X
-
Here is the error code:
NinjaScript File,Error,Code,Line,Column,
Strategy\MyCustomStrategy.cs,Operator '+' cannot be applied to operands of type 'NinjaTrader.Data.IDataSeries' and 'int',NT0019 - click for info,48,68,
Leave a comment:
-
see attachment for error
Note: c is defined as a double
#region Variables
private double c = 0;
Leave a comment:
-
maxsys, sorry for our late reply here. Which issue do you see with this Print? This would give you the main DoubleStochastic value, %K. You want to specify though which value you would want to access from it, since per default the method would give you a series return - http://www.ninjatrader.com/support/h...tochastics.htm
So adding a [0] index to your call would mean you want to print the value of the last closed bar that called OnBarUpdate() of your script.
Leave a comment:
-
Debug indicator in strategy
I am trying to debug entrys in a strategy using DoubleStochastics indicator. I don't understand objects and classes well enough.
Here is my code sample:
//c = DoubleStochastics(10).K;
//this.PrintWithTimeStamp("DS10 " + c.ToString("N2"));
TIATags: None
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by cupir2, Yesterday, 05:27 PM
|
1 response
14 views
0 likes
|
Last Post Today, 09:33 AM | ||
Started by HGTrader, Today, 09:31 AM
|
0 responses
1 view
0 likes
|
Last Post
by HGTrader
Today, 09:31 AM
|
||
Started by Gibranes, 10-12-2024, 04:02 AM
|
2 responses
13 views
0 likes
|
Last Post
by Gibranes
Today, 09:28 AM
|
||
Started by mirandacoman, Today, 09:23 AM
|
0 responses
2 views
0 likes
|
Last Post
by mirandacoman
Today, 09:23 AM
|
||
Started by dbennett3, Today, 09:18 AM
|
0 responses
4 views
0 likes
|
Last Post
by dbennett3
Today, 09:18 AM
|
Leave a comment: