NexusFi: Find Your Edge


Home Menu

 





Historical MAE Error?


Discussion in NinjaTrader

Updated
    1. trending_up 1,887 views
    2. thumb_up 2 thanks given
    3. group 1 followers
    1. forum 6 posts
    2. attach_file 1 attachments




 
Search this Thread

Historical MAE Error?

  #1 (permalink)
 
NJAMC's Avatar
 NJAMC 
Atkinson, NH USA
Market Wizard
 
Experience: Intermediate
Platform: NinjaTrader 8/TensorFlow
Broker: NinjaTrader Brokerage
Trading: Futures, CL, ES, ZB
Posts: 1,970 since Dec 2010
Thanks Given: 3,037
Thanks Received: 2,395

It doesn't seem like NT7 is calculating the MAE correctly on my historical trades. I did a quick check against the WIKI to make sure I understood the stat which I think of as the max draw-down during a single trade. This is how I calculate it within my own tools.

Here is a historical set of data:


The MAE ends up tracking the Profit for the trade (offset by the commission). Do I have something set wrong as I have lost some time because I saw some of these trades, set the Stop Loss to eliminate all the losing trades only to find many of the profitable trades now stop out (although they had a MAE = 0 prior to the SL being set).

It is clear the MAE=0 trades (some) dipped to a lose during the active trade, why doesn't this stats window reflect that fact?

Nil per os
-NJAMC [Generic Programmer]

LOM WIKI: NT-Local-Order-Manager-LOM-Guide
Artificial Bee Colony Optimization
Visit my NexusFi Trade Journal Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Better Renko Gaps
The Elite Circle
How to apply profiles
Traders Hideout
REcommedations for programming help
Sierra Chart
PowerLanguage & EasyLanguage. How to get the platfor …
EasyLanguage Programming
Pivot Indicator like the old SwingTemp by Big Mike
NinjaTrader
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Spoo-nalysis ES e-mini futures S&P 500
29 thanks
Tao te Trade: way of the WLD
24 thanks
Just another trading journal: PA, Wyckoff & Trends
23 thanks
Bigger Wins or Fewer Losses?
21 thanks
GFIs1 1 DAX trade per day journal
17 thanks
  #2 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,442 since Jun 2009
Thanks Given: 33,215
Thanks Received: 101,603

What bar type are you using? Use something like a range bar, not any exotic bar type built (not renko based) and see if it works.

Mike

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
  #3 (permalink)
 
NJAMC's Avatar
 NJAMC 
Atkinson, NH USA
Market Wizard
 
Experience: Intermediate
Platform: NinjaTrader 8/TensorFlow
Broker: NinjaTrader Brokerage
Trading: Futures, CL, ES, ZB
Posts: 1,970 since Dec 2010
Thanks Given: 3,037
Thanks Received: 2,395



Big Mike View Post
What bar type are you using? Use something like a range bar, not any exotic bar type built (not renko based) and see if it works.

Mike

I am using a simple 1 Min bar type. Nothing exotic, figured easiest case. Also noticed that ETD is equal to the commission for profitable trades, so something simply isn't working.

One thing to note is this is a MTF strategy, everything is traded on the primary 1 Min bar, but there is a 5min and 10 min bar as the 2nd and 3rd timeframe (only used for indicator calculations).

Nil per os
-NJAMC [Generic Programmer]

LOM WIKI: NT-Local-Order-Manager-LOM-Guide
Artificial Bee Colony Optimization
Visit my NexusFi Trade Journal Started this thread Reply With Quote
  #4 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,442 since Jun 2009
Thanks Given: 33,215
Thanks Received: 101,603


NJAMC View Post
I am using a simple 1 Min bar type. Nothing exotic, figured easiest case. Also noticed that ETD is equal to the commission for profitable trades, so something simply isn't working.

One thing to note is this is a MTF strategy, everything is traded on the primary 1 Min bar, but there is a 5min and 10 min bar as the 2nd and 3rd timeframe (only used for indicator calculations).

I suggest deleting the Documents\NinjaTrader 7\db\cache, and Documents\NinjaTrader 7\cache directory (stop Ninja and restart when doing this). I have had these become corrupted before, as have others, and cause all kinds of weird problems with backtests.

You might also repair your database, and/or "delete" it by renaming it to something else and restarting NinjaTrader to see if it solves the problem.

If none of these solve it then it's something with the strategy code, first prove a working sample on a single time frame strategy.

I cannot help much with MTF strategies because to be honest I gave up on getting them to work, just too many "gotchas" I kept running into. Are you using the LOM?

Mike

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
  #5 (permalink)
 
NJAMC's Avatar
 NJAMC 
Atkinson, NH USA
Market Wizard
 
Experience: Intermediate
Platform: NinjaTrader 8/TensorFlow
Broker: NinjaTrader Brokerage
Trading: Futures, CL, ES, ZB
Posts: 1,970 since Dec 2010
Thanks Given: 3,037
Thanks Received: 2,395


Big Mike View Post
I suggest deleting the Documents\NinjaTrader 7\db\cache, and Documents\NinjaTrader 7\cache directory (stop Ninja and restart when doing this). I have had these become corrupted before, as have others, and cause all kinds of weird problems with backtests.

You might also repair your database, and/or "delete" it by renaming it to something else and restarting NinjaTrader to see if it solves the problem.

If none of these solve it then it's something with the strategy code, first prove a working sample on a single time frame strategy.

I cannot help much with MTF strategies because to be honest I gave up on getting them to work, just too many "gotchas" I kept running into. Are you using the LOM?

Mike

I will give that a shot, Deleted the NT7\Cache directory earlier but I will try the db cache as well. I am not using LOM as of yet, might dust it off to handle some of these issues. Also might just print out my own stats, would be nice to use them within NT7 for debugging.

I will test it out tomorrow, need to turn in still recovering from a Cold or something...

Nil per os
-NJAMC [Generic Programmer]

LOM WIKI: NT-Local-Order-Manager-LOM-Guide
Artificial Bee Colony Optimization
Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #6 (permalink)
 
Big Mike's Avatar
 Big Mike 
Manta, Ecuador
Site Administrator
Developer
Swing Trader
 
Experience: Advanced
Platform: Custom solution
Broker: IBKR
Trading: Stocks & Futures
Frequency: Every few days
Duration: Weeks
Posts: 50,442 since Jun 2009
Thanks Given: 33,215
Thanks Received: 101,603


NJAMC View Post
I will give that a shot, Deleted the NT7\Cache directory earlier but I will try the db cache as well. I am not using LOM as of yet, might dust it off to handle some of these issues. Also might just print out my own stats, would be nice to use them within NT7 for debugging.

I will test it out tomorrow, need to turn in still recovering from a Cold or something...

I believe the db\cache directory is the one that used to cause me and others trouble, I delete the other one too because I can.

Good luck, feel better!

Mike

We're here to help: just ask the community or contact our Help Desk

Quick Links: Change your Username or Register as a Vendor
Searching for trading reviews? Review this list
Lifetime Elite Membership: Sign-up for only $149 USD
Exclusive money saving offers from our Site Sponsors: Browse Offers
Report problems with the site: Using the NexusFi changelog thread
Follow me on Twitter Visit my NexusFi Trade Journal Reply With Quote
Thanked by:
  #7 (permalink)
 
NJAMC's Avatar
 NJAMC 
Atkinson, NH USA
Market Wizard
 
Experience: Intermediate
Platform: NinjaTrader 8/TensorFlow
Broker: NinjaTrader Brokerage
Trading: Futures, CL, ES, ZB
Posts: 1,970 since Dec 2010
Thanks Given: 3,037
Thanks Received: 2,395

@Big Mike,

I had to restart NT7 as it crashed do to a bad coding problem, when I restarted, I tried a slightly different set of months of data. It seemed to of fixed itself when I did this, something was corrupt...

Thanks,
Greg

Nil per os
-NJAMC [Generic Programmer]

LOM WIKI: NT-Local-Order-Manager-LOM-Guide
Artificial Bee Colony Optimization
Visit my NexusFi Trade Journal Started this thread Reply With Quote




Last Updated on December 8, 2013


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts