NexusFi: Find Your Edge


Home Menu

 





Attack of the Robots - An Algo Journal


Discussion in Trading Journals

Updated
      Top Posters
    1. looks_one vmodus with 357 posts (859 thanks)
    2. looks_two SMCJB with 38 posts (84 thanks)
    3. looks_3 kevinkdog with 27 posts (70 thanks)
    4. looks_4 bobwest with 13 posts (53 thanks)
      Best Posters
    1. looks_one bobwest with 4.1 thanks per post
    2. looks_two kevinkdog with 2.6 thanks per post
    3. looks_3 vmodus with 2.4 thanks per post
    4. looks_4 SMCJB with 2.2 thanks per post
    1. trending_up 94,860 views
    2. thumb_up 1,141 thanks given
    3. group 61 followers
    1. forum 478 posts
    2. attach_file 181 attachments




 
Search this Thread

Attack of the Robots - An Algo Journal

  #461 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853

QQQ (proxy for NQ) looks much better. Here is the shuffled trades analysis for QQQ:



This system is a pain in my buttcheeks, though.

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:

Can you help answer these questions
from other members on NexusFi?
NT7 Indicator Script Troubleshooting - Camarilla Pivots
NinjaTrader
What broker to use for trading palladium futures
Commodities
Quantum physics & Trading dynamics
The Elite Circle
REcommedations for programming help
Sierra Chart
Strategy stop orders partially filled
EasyLanguage Programming
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Just another trading journal: PA, Wyckoff & Trends
24 thanks
What is Markets Chat (markets.chat) real-time trading ro …
19 thanks
ApexTraderFunding.com experience and review
17 thanks
GFIs1 1 DAX trade per day journal
13 thanks
EG Indicators
11 thanks
  #462 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853

And the final result of testing the Momentum Pinball:

Momentum Pinball 1 - Backtest Results


Among my goals is Profit Factor >= 1.5. Just by that measure, they all fail except QQQ. QQQ passed both Profit Factor and Adjusted Profit Factor (goal > 1.0).

I'll advance QQQ to incubation.

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #463 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853


QQQ failed Monte Carlo simulation. I expect at least 2.0 Return/Drawdown ratio. Even when lowering the starting equity to the minimum (~$3,000), it did not improve it enough to trade.



This idea might work with NQ futures, given the leverage futures provides, but that does not help me since I cannot trade futures right now. Maybe I could try a leveraged QQQ ETF.... hmmmm.

I'll post a link to the system post when I publish it tomorrow.

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #464 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853

So I tried a leveraged QQQ ETF (Nasdaq 100), TQQQ, which is 3x leveraged (though 'leveraged' ETF's are not quite leveraged at 3:1 ratio....won't get into specifics). Anyhow, it did no better than QQQ by itself.

I also tried ES for the past two years and compared to SPY over the same period. Just about the same profit factor, though a higher loss on ES due to higher trading costs and greater leverage. The signals were about the same.

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
  #465 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853

My post is live...

Systematic Algo Trader - Trading Idea 030 - [AUTOLINK]Momentum[/AUTOLINK] Pinball 1

This system was a pain. However, since I have had time to sleep on it... at least for QQQ, is it a bad system idea? I checked and the system is in the market less than 2% of the time and it is profitable for at least this instrument, maybe others I did not test yet. Maybe I trade it if I have capital lying around.

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #466 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853

I have started developing my next system, which is called Another Oddball System. It was created by Mark Brown in the mid-90's, but I could not get too much information other than the rules and instruments. It was published in the defunct Active Trader magazine.

The idea is to calculate Bollinger Bands based on a 10-period adaptive moving average (a/k/a Kaufman's Adaptive Moving Average). Here is what I am looking at (daily chart; instrument 3188.HK):


Entry long is above the top band; entry short is below. This is a stop-and-reverse (SAR) system that tries to capture trends and keep you in them for a very long time. I am adding my own twist to it, which is using a 2-period RSI to get a better entry. When the price closes outside of the bands, the instrument is often overbought or oversold, so I want for retracement prior to entry. My manual testing has shown this approach to be better a vast majority of the time. I did some analysis last year, posted in this journal, regarding the delayed entry on a PSAR system, which showed better results in a delayed entry, so this jives with what I am seeing.

I have not used Bollinger Bands in any of my algos, so this is new territory. I like the use of the KAMA rather than pure price, which is novel to me and interesting. I will be testing this on a basket of ETFs that will act as a proxy to the futures (I don't have all my futures data set up yet).

To be continued....

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #467 (permalink)
 
SMCJB's Avatar
 SMCJB 
Houston TX
Legendary Market Wizard
 
Experience: Advanced
Platform: TT and Stellar
Broker: Advantage Futures
Trading: Primarily Energy but also a little Equities, Fixed Income, Metals and Crypto.
Frequency: Many times daily
Duration: Never
Posts: 5,049 since Dec 2013
Thanks Given: 4,388
Thanks Received: 10,208


vmodus View Post
The idea is to calculate Bollinger Bands based on a 10-period adaptive moving average (a/k/a Kaufman's Adaptive Moving Average). Here is what I am looking at (daily chart; instrument 3188.HK):

Is the standard deviation calculation of the Bollinger Bands adaptive (ie using the same time period of the KAMA) as well?

Reply With Quote
Thanked by:
  #468 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853


SMCJB View Post
Is the standard deviation calculation of the Bollinger Bands adaptive (ie using the same time period of the KAMA) as well?

@SMCJB, in short, assuming I'm understanding your question, yes.

I forgot to provide the Bollinger Band parameters: 38 length.

So the parameters in MC should be the same in TS:
  • BollingerPrice: Indicator: "Mov Avg Adaptive" plot1 | Price = close | EffRatioLength = 10 | FastAvgLength = 2 | SlowAvgLength = 30
  • TestPriceUBand: Indicator: "Mov Avg Adaptive" plot1 | Price = close | EffRatioLength = 10 | FastAvgLength = 2 | SlowAvgLength = 30
  • TestPriceLBand: Indicator: "Mov Avg Adaptive" plot1 | Price = close | EffRatioLength = 10 | FastAvgLength = 2 | SlowAvgLength = 30
  • Length: 38
  • NumDevsUp: 3
  • NumDevsDn: -3
  • Displace: 0

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #469 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853

Going through my manual testing phase to determine feasibility, I tested this idea on a corn futures ETF (CORN):
  • No stops or risk management, just the entry and reversal signals
  • Oct 2010 through today (Mar 23)
  • I entered only when the 2-period RSI moved out of oversold/overbought (30/70)

Here is the equity curve, marked-to-market:


The RSI 'trick' for entry gave a better entry over 90% of the time. We are essentially waiting for the retracement. I think I read something from Perry Kaufman or other algo trader who indicated that waiting a day/bar or two for entry after a signal generally resulted in better returns.

If I used the SPY ETF to calculate alpha, the returns for this instrument and system idea do not beat a buy-and-hold of SPY over the same period:
  • SPY: 24.5% annual return
  • CORN: 11.9% annual return
  • Alpha = -12.6%
This is just one instrument and this idea is going to be tested over a basket/portfolio of instruments, one of which is SPY.

Just as a side note, I find the naming for some of these futures based ETF to be amusing (CORN, HOGS, COW, etc.).

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:
  #470 (permalink)
 
vmodus's Avatar
 vmodus 
Somewhere, Delaware, USA
 
Experience: Intermediate
Platform: MultiCharts
Broker: Barchart.com
Trading: Everything, it all tastes like chicken
Posts: 1,271 since Feb 2017
Thanks Given: 2,958
Thanks Received: 2,853


I have been trying to standardize, codify, and simplify the system development process, and I wanted to share the latest thing I've come up with. I am going to build a standard template for all the system code I develop from this point forward (EasyLanguage = Strategy; MultiCharts = Signal....I call it 'System'). I have built similar templates, but never settled on a standard. Here is my attempt to capture all the components I want to capture:

System Standard Components


Things this helps me with:
  • Prevent recoding the same thing over and over again
  • Standardizing things that I use time and again
  • Set a parameter when I want to switch between a fixed number of contracts/shares (forex, futures) to a variable one based on risk capital (equities, ETFs)
  • Select direction when working with long or short only system ideas
  • Select start and end dates for trading periods, useful for backtesting and walk-forward
  • Stop loss and profit targets, for system ideas that use those
  • Reinvestment of profit (or reducing position size when running a net loss)

Inputs:
values I set for the system
Variables: stored values
Processing: How the system uses the inputs and variables to manage system behavior

I know this is not a novel idea and I think I recall TradeStation allows you to create templates for EasyLanguage. The big thing for me is to not have to recode some basic, standard things I use time and again, although not with every system I build. I may create some functions to further simplify my code, such as a function to just calculate position size. Write once, use many.

It is a work in progress, but I'm pretty close. I am really just tired of having to rewrite code when I want to switch from forex testing to ETFs, for example.

~vmodus

Enjoy everything!
Follow me on Twitter Visit my NexusFi Trade Journal Started this thread Reply With Quote
Thanked by:




Last Updated on March 31, 2022


© 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