Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
EMA Charting
Collapse
X
-
EMA Charting
Hi, I can't seem to be able to write a code for strategy to simply show EMA 200 indicator on my chart, can you please help, attached is my code and I keep getting error "The type or namespace name 'Color' does not exist in the namespace 'System.Drawing' (are you missing an assembly reference?)" and I do have System.Drawing up on my code. Can you provide a simpler code just to show EMA 200 on chart or help to fix my code please? See attached.
Tags: None
-
Hello shahabjet1,
Thanks for your post.
If you are wanting to plot the EMA(200) on a chart, the AddPlot() method should be added to the script which will add a plot to the chart. The EMA(200)[0] value could then be assigned to that plot so that the script plots the EMA(200) on the chart when you add the indicator to the chart.
I have attached a simple example script demonstrating how this could be accomplished.
Note that NinjaTrader 8 uses Brushes to define the color of an object. For example, Brushes.Red would be used to set a plot or drawing to the color red.
See the help guide documentation below for more information.
AddPlot(): https://ninjatrader.com/support/help...t8/addplot.htm
EMA(): https://ninjatrader.com/support/help...onential_e.htm
Working with Brushes: https://ninjatrader.com/support/help...th_brushes.htm
Please let me know if I may assist you further on this topic.Attached Files<span class="name">Brandon H.</span><span class="title">NinjaTrader Customer Service</span><iframe name="sig" id="sigFrame" src="/support/forum/core/clientscript/Signature/signature.php" frameborder="0" border="0" cellspacing="0" style="border-style: none;width: 100%; height: 120px;"></iframe>
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Mindset, 04-21-2026, 06:46 AM
|
0 responses
90 views
0 likes
|
Last Post
by Mindset
04-21-2026, 06:46 AM
|
||
|
Started by M4ndoo, 04-20-2026, 05:21 PM
|
0 responses
137 views
0 likes
|
Last Post
by M4ndoo
04-20-2026, 05:21 PM
|
||
|
Started by M4ndoo, 04-19-2026, 05:54 PM
|
0 responses
68 views
0 likes
|
Last Post
by M4ndoo
04-19-2026, 05:54 PM
|
||
|
Started by cmoran13, 04-16-2026, 01:02 PM
|
0 responses
120 views
0 likes
|
Last Post
by cmoran13
04-16-2026, 01:02 PM
|
||
|
Started by PaulMohn, 04-10-2026, 11:11 AM
|
0 responses
71 views
0 likes
|
Last Post
by PaulMohn
04-10-2026, 11:11 AM
|

Comment