Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Can you help me to write an SMA indicator with weight parameter?
Collapse
X
-
Hello deathauto,
Thanks for your post.
I have moved this forum thread to the Indicator Development section of the Forums since you are asking about creating a custom indicator.
This would require creating a user-defined input parameter called something like 'Weight' and using that variable within your own custom logic.
To create a copy of the SMA indicator file to modify you can open a New > NinjaScript Editor window, open the Indicators folder, double-click on the SMA file, right-click within the SMA code, select 'Save as', name the copy of the file, and click 'OK'.
See this help guide page about creating custom user-defined input parameters: https://ninjatrader.com/support/help...d_input_pa.htm
The Strategy Builder could also be used to create a user-defined input parameter on the Inputs and Variables screen and then the 'View code' button could be clicked to generate and view the syntax.
Below is a link to a forum post with helpful information about getting started with NinjaScript.
https://ninjatrader.com/support/foru...040#post786040<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 Hwop38, 05-04-2026, 07:02 PM
|
0 responses
152 views
0 likes
|
Last Post
by Hwop38
05-04-2026, 07:02 PM
|
||
|
Started by CaptainJack, 04-24-2026, 11:07 PM
|
0 responses
304 views
0 likes
|
Last Post
by CaptainJack
04-24-2026, 11:07 PM
|
||
|
Started by Mindset, 04-21-2026, 06:46 AM
|
0 responses
244 views
0 likes
|
Last Post
by Mindset
04-21-2026, 06:46 AM
|
||
|
Started by M4ndoo, 04-20-2026, 05:21 PM
|
0 responses
345 views
0 likes
|
Last Post
by M4ndoo
04-20-2026, 05:21 PM
|
||
|
Started by M4ndoo, 04-19-2026, 05:54 PM
|
0 responses
175 views
0 likes
|
Last Post
by M4ndoo
04-19-2026, 05:54 PM
|

Comment