Site Meter The Lawyer Trader: Ninja Trader
Showing posts with label Ninja Trader. Show all posts
Showing posts with label Ninja Trader. Show all posts

Thursday, March 1, 2018

Tools of the Trade

Every now and again someone asks me about software, charts, tools, etc. that I use to trade.  Here's a quick list.  I'm considering doing a series of reviews of some of the different services sometime soon.

Broker:  Interactive Brokers

Great executions and low commissions.  Bells and whistles are missing..I'm not a big fan of their charts and various tools.  Just use them for trade execution.  Their customer service has been helpful when I've needed it but can't really speak to most of the technical tools or research they offer.

Trading Software:  Ninja Trader

Ninja Trader is the main software that I use to trade.  Currently trading on Ninja Trader 7.  I've played with NT8 and like it a lot..just easing into the new platform before I start actually using NT8 to trade live.  Charts are friendly and everything is very customizable.  There's a script editor based in C#, so custom programming is available.  Moreover, there's a pretty robust strategy wizard that makes it easy to program and test strategies without even knowing how to code.  Most importantly, you can implement your automated strategy and have ninja trader implement the trades through Interactive Brokers via an API connection..this is the main reason that I started trading with Ninja Trader.

Server:  Speedy Trading Servers

I run all my trading software and brokerage software on a server with speedytradingservers.com.  They are very reliable, reasonably priced, and have had great customer service.  Highly recommend them if you're running automated strategies.

Others:  

Bloodhound by Shark Indicators

An add in to Ninja Trader.  Pretty nice tool that allows you to develop indicators and strategies within Ninja Trader.

Meta Trader 4

I use MT4 some for currency trading.  There are just some features with this platform that I like, especially on the automated side.  It's not as robust as Ninja Trader but it works well if you're focused on trading currencies.

Amibroker

Same as MT4 but for other reasons.  There are features in Amibroker that are cool for strategy testing and development that you don't find on other platforms.  I don't use this one that much but have found it to be useful at times.

ThinkorSwim by TD Ameritrade

I do a little bit of trading on TOS but not much over the last 4-5 years.  I still like some of the features in TOS and really like the ease of programming indicators and strategies.  Unfortunately, there's no way to actually automate any of the strategies which is why I made the jump to Ninja Trader.  Still, it has some nice features, especially for collecting data on multiple instruments or for options.  If I were sitting in front of the screens and discretionary trading all day, I'd have a screen with TOS open.

Futures.io

A great site.  The Admin and big dog, Big Mike, really did the trading community a service by getting this up and keeping it going over the years.  I've mostly been a lurker on this site but have found the members area to be very helpful for getting indicators and trading ideas.  It's a nominal subscription fee and is worth every penny.

IQ Feed

While I currently am not using IQ Feed, I have used them in the past.  I pay for the direct stream data from the exchanges for trading but have used IQ Feed for historical data for testing purposes.  It's very good and reasonably priced.

Tick Data Suite by EAReview

This is a must if you are testing strategies in MT4 or MT5.  The tick data is high quality and allows you to test strategies with a very high quality tick modelling rate.  Essential if you are testing strategies and want to have an idea of what they will actually trade like when you go live.  Very reasonably priced as well.

Strategy Quant

A very cool strategy development tool.  It uses random generation and genetic optimization to test thousand upon thousands of combinations of signals to develop strategies and then it lets you export the strategies into a code for Ninja Trader, Meta Trader, TradeStation.  The exported strategies are pre-coded with nice money management and profit target/stop loss features.  Overall its a cool program, however,  it is major curve fitting and there are some frustrating aspects to the program itself.  I've heard the customer support is not very good..I've never tried contacting them.  Needless to say, it's a decent program and I've pulled 2 strategies from it that I've live traded.

Build Alpha

Build Alpha offers the Traders Tool Box and I've only recently purchased it and started playing with it.  So far, I'm very impressed.  It's similar to Strategy Quant, in that you can use optimization to test thousands of entry and exit signals to develop strategies and then export trading code to some of the main trading platforms on the market.  David, the founder/owner is very helpful and responsive and he posts a bunch of helpful videos on the website that walk you through the whole program.  The main features that jump out at me so far are the various built in statistical tests for validating strategies and the ability to save multiple strategies into a portfolio and test the portfolio as a whole.  Very unique and very cool.  I'll be spending a lot of time on this one in the near future.

I'm sure there are a few things that I'm forgetting and I'll update this post later if I think of anything.  There are definitely plenty of tools readily available today that are mind blowing compared to what was available just 10 years ago.  There's no perfect software or tool, they all have their pros and cons but this is just a list of some of the resources that I have found useful.  FYI, I was not asked to post any reviews and I have paid regular prices for all of the services (I'm not big enough for people to give me free stuff in return for reviews..lol(although I was asked years ago to review a Harry Dent book in exchange for a review..I declined..lol)).

Happy Trading.

TheLawyerTrader
George

Friday, August 16, 2013

A Pivot Point Trading System for Ninja Trader: Are pivot points profitable?

I've never been that big on pivot points, however, I do find them interesting and began dabbling with them recently.  Pivot points are generally used on an intra-day basis, however, for this system, I used them on daily bars and calculated the values off of the weekly time frame.  As it turns out, there is some decent profit potential with a simple pivot point system.  I devised a basic mean reversion system and have applied it to Sector ETFs.  Here are the rules:

Enter Long
  • Close is greater than 200 day simple moving average;
  • Close crosses below S2.
  • Close crosses below S3, enter a second long position.
Exit the trade when the close crosses above the PP (middle point)

Enter Short
  • Close is less than 200 day simple moving average;
  • Close crosses above S2;
  • Close crosses above S3, enter a second short position.
Exit the trade when the close crosses below the PP (mid point)

Here's a screen shot:

As you can see, this system buys dips and sells rallies.  The 200 day moving average is a basic filter to screen for trades that are in the same direction as the trend.  It's not the most sophisticated filter but it works just fine.

And the results please.  I back-tested this system from 2008-today (Aug. 16, 2013).  It is profitable, although not overwhelmingly, jaw-dropping profitable.  One very positive factor is that it has pretty low drawdowns.  With a basket of 12 etfs, it trades all through the volatility of 08' and 11' and the trending markets of 09' and 13' and it has had a max drawdown of -5.68%.  That's pretty good.  The cumulative profit is 39% but when you consider that profit with such a small drawdown, it makes this system look more attractive.  (Note, I did not take out commissions or slippage.  These will affect results some, but not too much as this is traded on a daily time frame.) Someone could apply 2x1 leverage and get a return of nearly 80% with a -11-12% drawdown, which is much more impressive.  Another nice quality is the rather high winning percentage of 78.87%..which is about normal for a profitable mean reversion system.  This can be good for traders that "have" to win more often than they lose, which is not necessary for a profitable system but it may be more in line with a trader's psychological makeup. 

Here are the reports for the portfolio as a whole and the individual etfs.  They were all profitable, some much more than others.


Here are the stats for the portfolio as a whole with couple of annotations pointing out some of the more relevant metrics.

So am I going to trade this system?  Probably not, at least not right now.  I've actually got better performing mean reversion systems that I'm currently trading (and by better performing, I don't just mean more profitable--that is part of it but the other systems also have a better history and they trade in a manner that I am 100% comfortable with and that I completely understand).  I will however, still play around with this idea and see if I can tweak it a little more to my liking.  Another thing that's worth is exploring is working a similar system on an intra-day time frame.  That will take a little more work and I'll gladly post an update later to let you know of any progress.

For those of you who use ninja trader, below is the ninja script (NT7) for the system.

Hope everyone is enjoying that last bit of summer.  

TLT

*******Delete this line when you paste into NT*******
#region Using declarations
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Drawing;
using System.Drawing.Drawing2D;
using System.Xml.Serialization;
using NinjaTrader.Cbi;
using NinjaTrader.Data;
using NinjaTrader.Indicator;
using NinjaTrader.Gui.Chart;
using NinjaTrader.Strategy;
#endregion

// This namespace holds all strategies and is required. Do not change it.
namespace NinjaTrader.Strategy
{
    /// <summary>
    /// Enter the description of your strategy here
    /// </summary>
    [Description("Enter the description of your strategy here")]
    public class DailyPivotTrader : Strategy
    {
        #region Variables
        // Wizard generated variables
        private int ma = 200; // Default setting for Ma
        // User defined variables (add any user defined variables below)
        #endregion

        /// <summary>
        /// This method is used to configure the strategy and is called once before any strategy method is called.
        /// </summary>
        protected override void Initialize()
        {

            CalculateOnBarClose = true;
        }

        /// <summary>
        /// Called on each bar update event (incoming tick)
        /// </summary>
        protected override void OnBarUpdate()
        {
            // Condition set 1
            if (CrossBelow(Close, Pivots(PivotRange.Weekly, HLCCalculationMode.DailyBars, 0, 0, 0, 20).S2, 1)
                && Close[0] > SMA(Ma)[0])
            {
                EnterLong(DefaultQuantity, "");
            }

            // Condition set 2
            if (CrossBelow(Close, Pivots(PivotRange.Weekly, HLCCalculationMode.DailyBars, 0, 0, 0, 20).S3, 1)
                && Close[0] > SMA(Ma)[0])
            {
                EnterLong(DefaultQuantity, "");
            }

            // Condition set 3
            if (CrossAbove(Close, Pivots(PivotRange.Weekly, HLCCalculationMode.DailyBars, 0, 0, 0, 20).R2, 1)
                && Close[0] < SMA(Ma)[0])
            {
                EnterShort(DefaultQuantity, "");
            }

            // Condition set 4
            if (CrossAbove(Close, Pivots(PivotRange.Weekly, HLCCalculationMode.DailyBars, 0, 0, 0, 20).R3, 1)
                && Close[0] < SMA(Ma)[0])
            {
                EnterShort(DefaultQuantity, "");
            }

            // Condition set 5
            if (CrossAbove(Close, Pivots(PivotRange.Weekly, HLCCalculationMode.DailyBars, 0, 0, 0, 20).PP, 1))
            {
                ExitLong("", "");
            }

            // Condition set 6
            if (CrossBelow(Close, Pivots(PivotRange.Weekly, HLCCalculationMode.DailyBars, 0, 0, 0, 20).PP, 1))
            {
                ExitShort("", "");
            }
        }

        #region Properties
        [Description("")]
        [GridCategory("Parameters")]
        public int Ma
        {
            get { return ma; }
            set { ma = Math.Max(1, value); }
        }
        #endregion
    }
}

*******Delete this line********


Wednesday, January 28, 2009

A Look at the Eur/Usd Pair and Ninja Trader

The Eur/Usd rallied a little over the past couple of days and has now stalled out. It seems that we've reached a pivotal point and soon we will should see a pretty big move in one direction or the other. The Eur/Usd rally topped out around the 1.3330 area and it has fallen back from that level twice now. I think the important breaking levels for the pair are 1.34 and 1.31. A break and close on the daily chart that is beyond either of these levels will most likely confirm a move in that direction. Here's an hourly chart that shows the overhead resistance level that the pair has not been able to break so far.
I'm still short the pair because my daily trend following system is giving the short signal for the Eur/Usd but it appears that a buy signal is not far away if the current rally continues...note that sometimes this situation (i.e. having a signal in one direction but being on the brink of change) provides a great low risk entry in the direction of the primary trend.

On a different note, I have downloaded and started playing around with Ninja Trader recently. This is an interesting platform that allows for free advanced charting and trading simulation. I'm mostly interested in the simulation trading. You can trade actual back data as if you were in real-time and you can also trade randomly generated data to hone your trading skills.

Practice trading is something that I've been meaning to do for quite some time now, but I never could get around to it. According to many trading coaches and learning experts, practicing in structured environments on a regular basis is an important step that helps in gaining the skills necessary to successfully take on a major endeavor like trading. I'm still getting to know and getting comfortable with the Ninja Trader software but I hope that it will be a valuable learning tool and I will post an update and review of the program once I get some more experience with it. I encourage you to give it or another similar type of program a try to see if it helps your trading.

Good luck out there.

TLT