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

Alert on touch of price on Donchian centerline

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

    Alert on touch of price on Donchian centerline

    A question about what is presumably a basic function in NT8 : what is the simplest way of setting an alert to sound every time price touches the centerline ("mean") of the standard DonchianChannel indicator, please ?

    Within Market Analyzer or some other way directly via the chart in question ?

    #2
    Hello jtrade,

    Thank you for your note.

    I put together a sample strategy which will draw an arrow and trigger a sound alert when the price crosses above the mean of the channel.

    You could modify the script in the strategy builder to add logic for crossing below, as well as define a touch.

    From within the builder you could click the View Code button, and copy this code over to an indicator if you'd prefer that.

    Please let us know if you need further assistance.
    Attached Files
    Alan P.NinjaTrader Customer Service

    Comment


      #3
      Alan - I have tried to copy-paste your code into a blank indicator page, but all i can get is a new indicator wizard.

      My intention is to go blank indicator page>paste your strat code twice>modify one side to short>remove strat components> finish with indicator alert I require. I used to be able to this simply with TradeStation.

      Help, please, bearing in mind I use NinjaTrader to trade, not to learn programming.

      Comment


        #4
        Hello jtrade,

        I would suggest importing the script I provided using the following steps,

        To Import a NinjaScript into NinjaTrader 8 do the following:

        From the Control Center window select Tools -> Import-> NinjaScript...
        Find the file location.

        Please let us know if you need further assistance.
        Alan P.NinjaTrader Customer Service

        Comment


          #5
          Thanks, Alan - that was the first thing I did to open the strat in the Editor to copy it... it's the next stage I'm stuck at : opening a blank indicator page to paste into (as per my post)... !?

          Comment


            #6
            Hello jtrade,

            Copying and pasting all the text from a strategy into an indicator would not be suggested.

            I would suggest trying to copy the text I circled in red from the strategy file to a new indicator file.

            Please let us know if you need further assistance.
            Attached Files
            Alan P.NinjaTrader Customer Service

            Comment


              #7
              Never mind.

              Comment


                #8
                Hello jtrade,

                To open a new blank indicator, go to Control Center>New>NinjaScript Editor.

                Right click on the indicator folder to the right>new indicator.

                Click Generate.

                Please let us know if you need further assistance.
                Alan P.NinjaTrader Customer Service

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by philmg, Today, 01:17 PM
                0 responses
                1 view
                0 likes
                Last Post philmg
                by philmg
                 
                Started by cre8able, Today, 01:01 PM
                1 response
                4 views
                0 likes
                Last Post NinjaTrader_ChelseaB  
                Started by manitshah915, Today, 12:59 PM
                1 response
                3 views
                0 likes
                Last Post NinjaTrader_Erick  
                Started by ursavent, Today, 12:54 PM
                1 response
                4 views
                0 likes
                Last Post NinjaTrader_Jesse  
                Started by Mizzouman1, Today, 07:35 AM
                3 responses
                17 views
                0 likes
                Last Post NinjaTrader_Gaby  
                Working...
                X