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 helpwanted, Today, 03:06 AM
              1 response
              5 views
              0 likes
              Last Post sarafuenonly123  
              Started by Brevo, Today, 01:45 AM
              0 responses
              7 views
              0 likes
              Last Post Brevo
              by Brevo
               
              Started by aussugardefender, Today, 01:07 AM
              0 responses
              5 views
              0 likes
              Last Post aussugardefender  
              Started by pvincent, 06-23-2022, 12:53 PM
              14 responses
              242 views
              0 likes
              Last Post Nyman
              by Nyman
               
              Started by TraderG23, 12-08-2023, 07:56 AM
              9 responses
              384 views
              1 like
              Last Post Gavini
              by Gavini
               
              Working...
              X