• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Moving average crossover alert

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

  • NinjaTrader_Jesse
    replied
    Hello DANIEL.JIMENEZ,

    Thank you for the reply.

    Regarding finding indicators, you can search for various indicators on the forum here in the file sharing section: https://ninjatrader.com/support/foru...splay.php?f=37

    Here is a link to the search for extension: https://ninjatrader.com/support/foru...&keys=1&ents=1

    You can also use the internet to search for more specific items to see if they have been created. If the item has not yet been created you or a third party may need to create it for the platform. NinjaTrader allows for the development of items using C# programming language.

    I look forward to being of further assistance.

    Leave a comment:


  • DANIEL.JIMENEZ
    replied
    MA Cross Over

    Thank you for your reply!

    I´m needing the tools to ensamble my trade chart, and in my ninja trander 7 I don´t have so many indicators like the MA Cross Over, between others.

    So I need to know if you have a Library where I can find this indicators that I don´t have in my NT7.

    I´ll be attentive.

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello DANIEL.JIMENEZ,

    Thank you for the post.

    Can you detail further what extensions you are referring to? Is this the Fibonacci extensions you are trying to access? You noted MACrossOver extension, are you referring to when the MA's cross over and produce a signal?

    I look forward to being of further assistance.

    Leave a comment:


  • DANIEL.JIMENEZ
    replied
    MA Cross Over

    Hello!

    Please I need the MA Cross Over extention, and others...so, can you please give me the route to find all the extentions? Thank you so much for your support.

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello,

    Thank you for updating me.

    For a message box there is no supported way of doing this. In C# you are able to open a popup message box by using MessageBox.

    To do this you would need to add a using statement at the top of the script

    Code:
    using System.Windows.Forms;
    Then where you want the popup to show do the following:

    Code:
    MessageBox.Show("test message insert any string here");
    I look forward to being of further assistance.

    Leave a comment:


  • trader333
    replied
    It was false on bar close. Problem fixed. Thanks. What about adding a pop up message box?

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello,

    I am unsure of this,

    What do you have CalculateOnBarClose set to and also are you using a re arm time it looks like that is defined in the script as a user input.

    I look forward to being of further assistance.

    Leave a comment:


  • trader333
    replied
    5 minute chart

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello,

    Can you please tell me what type of chart you are using this with?

    I tried this on a few different types but was unable to get the results that you are, This would be expected if you were using it on a 1 tick or with CalculateOnBarClose as false.

    I Look forward to being of further assistance.

    Leave a comment:


  • trader333
    replied
    Jesse
    is it possible for this indicator you posted in post #16 to alert crossover once per bar at the end of bar close, right now it alerts on every tick after crossover.
    A stand alone pop up is also useful to draw attention with instrument name period and crossover time.

    Leave a comment:


  • dline
    replied
    Ok I will try this unfortunately I've run out of time to respond tonight but I'll try it and get back to you
    Cheers
    dline

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello,

    Thank you for clearing that up.

    For this sort of indicator there is actually not a whole lot of code required.

    For the cross event, you can use something like the following to detect when the price crosses the MA. I will use an SMA for this example but you can replace this with which ever indicator you choose to use.

    Code:
    if (CrossAbove(Close, SMA(14), 1))
    {
         DrawSquare("CrossAboveSquare" + CurrentBar, true, 0, Close[0], Color.Green);
    }
    if (CrossBelow(Close, SMA(14), 1))
    {
         DrawSquare("CrossBelowSquare" + CurrentBar, true, 0, Close[0], Color.Red);
    }
    Something like this would draw a square each time the Cross above or below event happens.

    Let me explain this a bit,

    In the statement:
    Code:
    if (CrossAbove(Close, SMA(14), 1))
    This would be comparing the Close data series against the SMA with a period of 14 data series, the 1 signifies a lookback period of 1, so this would check each bar if there was a cross on the last bar.

    Code:
    DrawSquare("CrossAboveSquare" + CurrentBar, true, 0, Close[0], Color.Green);
    There is a important note here with the drawing objects, the tag name: "CrossAboveSquare" + CurrentBar will allow a new square to be placed and leaves the other squares that have already been placed alone because its tag name is unique, if the tag name was instead "CrossAboveSquare" only one square could be present on the chart at a time.

    Here is some documentation for the methods used above:
    http://www.ninjatrader.com/support/h.../nt7/close.htm
    http://www.ninjatrader.com/support/h...sub=crossabove

    This is the drawing section, the DrawSquare is one of many drawing methods so please adjust to your needs.
    http://www.ninjatrader.com/support/h...t7/drawing.htm

    Leave a comment:


  • dline
    replied
    Originally posted by NinjaTrader_Jesse View Post
    Hello,

    Thank you for the clarification.

    For your question,

    This depends what sort of popup you are trying to create. Are you looking for some sort of text that appears on the chart or something that physically pops up?

    Also you said that this is not a moving average cross over question but you are asking for this to happen when the price moves through your moving average, do you mean when it crosses above or below the moving average? Can you please clarify this?

    You are correct you would need to create an indicator for this, I can assist you in providing the information to help you but we will need to clear up the above questions first.

    I look forward to being of further assistance.
    HI, as far as a "pop up ... a square (symbol) will do on the chart or even a sound alert.
    About moving average cross I mean not 2 moving averages crossing etc.
    I mean when price crosses above moving average a blue square appears on chart
    Then when price crosses below moving average a red square appears on the chart
    Thank you you've been great

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello,

    Thank you for the clarification.

    For your question,

    This depends what sort of popup you are trying to create. Are you looking for some sort of text that appears on the chart or something that physically pops up?

    Also you said that this is not a moving average cross over question but you are asking for this to happen when the price moves through your moving average, do you mean when it crosses above or below the moving average? Can you please clarify this?

    You are correct you would need to create an indicator for this, I can assist you in providing the information to help you but we will need to clear up the above questions first.

    I look forward to being of further assistance.

    Leave a comment:


  • dline
    replied
    My apologies some times it's hard to find the right thread.

    This is a chart related question, after it's creation I want to be able to open indivators and add it to my chart.

    Thank you

    Leave a comment:

Latest Posts

Collapse

Topics Statistics Last Post
Started by memonic, Today, 02:21 AM
0 responses
2 views
0 likes
Last Post memonic
by memonic
 
Started by Guru73, Yesterday, 02:47 AM
5 responses
30 views
0 likes
Last Post Guru73
by Guru73
 
Started by Guru73, Today, 01:35 AM
0 responses
1 view
0 likes
Last Post Guru73
by Guru73
 
Started by Maxwell123, Today, 12:34 AM
0 responses
4 views
0 likes
Last Post Maxwell123  
Started by esquissa, Yesterday, 11:59 PM
0 responses
2 views
0 likes
Last Post esquissa  
Working...
X