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 cmoran13, 04-16-2026, 01:02 PM
|
0 responses
43 views
0 likes
|
Last Post
by cmoran13
04-16-2026, 01:02 PM
|
||
|
Started by PaulMohn, 04-10-2026, 11:11 AM
|
0 responses
26 views
0 likes
|
Last Post
by PaulMohn
04-10-2026, 11:11 AM
|
||
|
Started by CarlTrading, 03-31-2026, 09:41 PM
|
1 response
163 views
1 like
|
Last Post
|
||
|
Started by CarlTrading, 04-01-2026, 02:41 AM
|
0 responses
98 views
1 like
|
Last Post
by CarlTrading
04-01-2026, 02:41 AM
|
||
|
Started by CaptainJack, 03-31-2026, 11:44 PM
|
0 responses
158 views
2 likes
|
Last Post
by CaptainJack
03-31-2026, 11:44 PM
|

Comment