So, how to put Cumulative profit graph (or other result's graph) in the chart in Strategy Analyzer?
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Put Cumulative profit graph in the chart in Strategy Analyzer
Collapse
X
-
-
I tried to create an indicator, but I don't know how to associate indicator with strategy. This lead to error in indicator:
Code:Plot0.Set(Performance.AllTrades.TradesPerformance.Points.CumProfit);
I tried with
Code:DrawLine("MyCumProfit"+CurrentBar, false, 1, Performance.AllTrades.TradesPerformance.Percent.CumProfit, 0, Performance.AllTrades.TradesPerformance.Percent.CumProfit, Color.Gray, DashStyle.Dot, 1);
Comment
-
Hello alexstox,
You may want to just plot from within the strategy for the easiest way to do something like this so you do not have to worry about passing variables from your Strategy to your Indicator which can be difficult.
Here is an example of how you can Plot from within a strategy that you may view.
When running a strategy on a chart you may find the need to plot values onto a chart. If these values are internal strategy calculations that are difficult to migrate to an indicator, you can use the following technique to achieve a plot. NinjaTrader 8 With NinjaTrader 8 we introduced strategy plots which provide the abilityJCNinjaTrader Customer Service
Comment
-
Hello alexstox,
Nothing comes to mind to easily be able to do what you looking for. Drawing objects in a Strategy will be on the same scale and writing the values to a file in the Strategy Analyzer can run into issue with file accessing.
Is this something that you want visually? If you use the DrawText() method you should be able to Display the Cumulative Profit when your trades enters or exits.JCNinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by fx.practic, 10-15-2013, 12:53 AM
|
5 responses
5,404 views
0 likes
|
Last Post
by Bidder
Today, 12:22 AM
|
||
Started by Shai Samuel, 07-02-2022, 02:46 PM
|
4 responses
95 views
0 likes
|
Last Post
by Bidder
Today, 12:11 AM
|
||
Started by DJ888, Yesterday, 10:57 PM
|
0 responses
7 views
0 likes
|
Last Post
by DJ888
Yesterday, 10:57 PM
|
||
Started by MacDad, 02-25-2024, 11:48 PM
|
7 responses
159 views
0 likes
|
Last Post Yesterday, 10:23 PM | ||
Started by Belfortbucks, Yesterday, 09:29 PM
|
0 responses
8 views
0 likes
|
Last Post
by Belfortbucks
Yesterday, 09:29 PM
|
Comment