Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

How to generate a NinjaScript (my indicator) ???

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How to generate a NinjaScript (my indicator) ???

    Hi guys,

    I've a code. Please, could you help me step by step, to transform this code in a NinjaScript (my indicator)???

    Here is part of the code. I THINK this code is Easy Language:


    #region Using declarations
    using System;
    using System.Diagnostics;
    using System.Drawing;
    using System.Drawing.Drawing2D;
    using System.ComponentModel;
    using System.Xml.Serialization;
    using NinjaTrader.Data;
    using NinjaTrader.Gui.Chart;
    #endregion

    // This namespace holds all indicators and is required. Do not change it.
    namespace NinjaTrader.Indicator
    {

    /// <summary>
    /// This method is used to configure the indicator and is called once before any bar data is loaded.
    /// </summary>
    protected override void Initialize()
    {
    Add(new Plot(Color.Cyan, "Plot1_Up"));
    Add(new Plot(Color.Magenta, "Plot1_Dn"));
    Add(new Plot(Color.Cyan, "Plot2_Up"));
    Add(new Plot(Color.Magenta, "Plot2_Dn"));


    value1 = new DataSeries(this);
    value2 = new DataSeries(this);

    Overlay = true;
    PriceTypeSupported = true;

    BarsRequired = length+trigAvg;
    }


    Tks and

    Best regards

    #2
    Looks like 100% Ninja script.

    Comment


      #3
      How to generate a NinjaScript zip file?

      Comment


        #4
        Originally posted by traderfranco View Post
        How to generate a NinjaScript zip file?
        In Control Center goto File -> Utilties -> Export NinjaScript

        Immediately you will need to decide:
        Do you want to export your indicator as source code or as a DLL assembly?

        Start reading here:

        Comment


          #5
          I think you didn't understand my issue. I want to GENERATE a NinjaScript zip file.

          I DON'T WANT export NinjaScript.

          Comment


            #6
            Originally posted by traderfranco View Post
            I think you didn't understand my issue. I want to GENERATE a NinjaScript zip file.

            I DON'T WANT export NinjaScript.
            A NinjaScript zip file contains code for NinjaScript indicators and/or strategies.

            Generally speaking, generating a NinjaScript zip file *EXACTLY* means you are exporting NinjaScipt code.

            What do you think 'generating a NinjaScript zip file' means?

            What exactly are you trying to achieve?

            Comment


              #7
              Originally posted by traderfranco View Post
              I think you didn't understand my issue. I want to GENERATE a NinjaScript zip file.

              I DON'T WANT export NinjaScript.
              Use winzip, http://www.winzip.com/win/en/index.htm to create zip files.

              Or most version of windows can create a zipped file, right click in windows explorer,
              Intelligent search from Bing makes it easier to quickly find what you&#8217;re looking for and rewards you.


              Not sure what you'll get with a zipped file, but that's not my problem.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by wzgy0920, 04-20-2024, 06:09 PM
              2 responses
              26 views
              0 likes
              Last Post wzgy0920  
              Started by wzgy0920, 02-22-2024, 01:11 AM
              5 responses
              32 views
              0 likes
              Last Post wzgy0920  
              Started by wzgy0920, Yesterday, 09:53 PM
              2 responses
              49 views
              0 likes
              Last Post wzgy0920  
              Started by Kensonprib, 04-28-2021, 10:11 AM
              5 responses
              192 views
              0 likes
              Last Post Hasadafa  
              Started by GussJ, 03-04-2020, 03:11 PM
              11 responses
              3,234 views
              0 likes
              Last Post xiinteractive  
              Working...
              X