StockFetcher Forums · Stock Picks and Trading · THE RISE OF ARTIFICIAL INTELLIGENCE: MY 2018 NEURAL NETWORK TRADING SYSTEMS<< >>Post Follow-up
Kevin_in_GA
4,599 posts
msg #140338
Ignore Kevin_in_GA
12/22/2017 10:32:50 PM

So as 2017 comes to a close I once again begin to think about how I traded over the course of the year (mostly good, a few really bad trades), what my main investment vehicles have been (XIV mostly) and what my trading approaches have been (mean reversion, gap fades, Stratasearch multisystems, etc.). Overall I had one of my best years ever, but I probably could have done better if I had

1. Been more committed to following system signals rather than trying to "out-think" my own trading systems.

2. Spent more time developing systems across a broader range of investments, rather than mostly shorting volatility, and

3. Traded less often, rather than more often.

While the first issue is purely psychological, and last two can be addressed by taking time to look at other investment options, other trading strategies, and thinking more deeply about managing risk - I cannot think that 2018 will look anything like 2017 did, where it was hard NOT to make money. I had occasionally placed nearly all of my trading capital into a single asset (XIV) which worked out okay in the end but was not actually a good risk management approach. While the current low volatility environment may continue for some time, it would be wise to look at other non-correlated assets that could provide good returns while spreading some risk across my portfolio.

STEP 1: FINDING HIGHLY LIQUID TRADEABLE NON-CORRELATED ASSETS

To start off the new year, I want to keep XIV as part of a core set of investments, but to identify a larger set of uncorrelated assets that can be easily traded with no liquidity issues. This wasn't really hard to do, using SF code to identify correlation levels and average volumes for a host of potential ETFs. This got me down to a good core set of 12 ETFs that have over 1, 3, and 5 year timeframes shown low correlation with XIV and with each other.

Here is the correlation matrix for these ETFs from 12/01/2016 until 12/01/2017:

NameTickerXIVGDXOILRSXSLVUNGXOPXBIJOFXISMHVNQ
VelocityShares Daily Inverse VIX ST ETNXIV-0.010.230.440.010.010.410.480.150.590.650.51
VanEck Vectors Gold Miners ETFGDX0.01-0.180.230.710.050.230.040.160.070.040.18
iPath S&P GSCI Crude Oil TR ETNOIL0.230.18-0.580.180.160.680.140.180.250.170.08
VanEck Vectors Russia ETFRSX0.440.230.58-0.230.120.610.260.180.480.410.31
iShares Silver TrustSLV0.010.710.180.23-0.050.130.010.180.080.010.16
United States Natural GasUNG0.010.050.160.120.05-0.20-0.010.050.03-0.03-0.03
SPDR S&P Oil&Gas Explor&Prodtn ETFXOP0.410.230.680.610.130.20-0.300.170.390.350.22
SPDR S&P Biotech ETFXBI0.480.040.140.260.01-0.010.30-0.030.370.470.29
iPath Bloomberg Coffee SubTR ETNJO0.150.160.180.180.180.050.170.03-0.160.100.15
iShares China Large-Cap ETFFXI0.590.070.250.480.080.030.390.370.16-0.580.38
VanEck Vectors Semiconductor ETFSMH0.650.040.170.410.01-0.030.350.470.100.58-0.36
Vanguard REIT ETFVNQ0.510.180.080.310.16-0.030.220.290.150.380.36-


The correlations between OIL and XOP (0.68), and between SLV and GDX (0.71) are a little higher than I might want, but for reasons explained later I want to keep these guys in the mix.

STEP 2: FINDING PROFITABLE TRADING SYSTEMS

Since about midsummer I have been playing around with a new trading system development software called Stock NeuroMaster Pro, which uses neural networks to identify patterns (long and short) in stock data and convert them into profitable trading systems. To be honest, these systems work great but are completely opaque in terms of what they do and how they do it.

Important Point - these cannot be translated into any other code, especially Stockfetcher, so don't ask.

To get a better understanding of what neural networks are and how they work, this video I found to be very helpful.



I have been slowly learning how to get the most out of the software, and am at the point where I can share some of my thinking and the system results.

STEP 3: SYSTEM RESULTS AND 10 YEAR PERFORMANCE

Part of the challenge in trading is not knowing when things will get nasty - we have recently been through a brutal Recession in 2008/2009, but since then it has been an incredible bull market backed by the Fed, near zero interest rates, and multiple rounds of Quantitative Easing. Those days are coming to an end, so any system that you might trade needs to be tested against time frames that include both Bear and Bull markets.

I wanted to do less daily trading and start to focus on weekly data sets, so I chose to develop all of the Neural network systems against weekly data from 12/01/2007 through 12/01/2017 (or from the ETF's date of inception through to 12/01/2017 if it did not exist before 2008). This period caught all of the 2008/2009 recession as well as the 8 year bull market we are currently in.

Going into 2018, all my systems need to be designed to trade their ETF both long and short, and do so with high returns and high win rates. This was something I could not really do in Stratasearch since it only uses daily data, and having tried to develop systems over this time period I never found one that performed all that well.

However, this ended up being a trivial task for the neural network systems. The trade durations are typically 8-10 weeks long, which is an eternity to a lot of folks here on SF. However, you can't really argue with the results ...


Model:FXIGDXJOOILRSXSLVSMHUNGVNQXBIXIVXOP
Trading period:08/11/08-08/07/1708/25/08-11/27/1705/04/09-12/04/1709/10/07-12/04/1708/11/08-11/27/1708/25/08-11/27/1708/25/08-08/14/1708/11/08-12/04/1709/29/08-12/11/1708/18/08-12/04/1708/15/11-12/11/1708/25/08-12/18/17
Profit (%):478.6888.4532.4775.2714.7665.5446.6661.5426.9600.7960.8654.1
Total net profit $478,603.57 $888,425.08 $532,415.97 $775,156.47 $714,654.28 $665,533.31 $446,582.66 $661,506.74 $426,918.00 $600,722.08 $960,765.67 $654,114.85
Gross profit $482,161.33 $888,425.08 $532,415.97 $776,331.96 $716,871.02 $668,433.57 $447,493.85 $662,142.36 $426,918.00 $600,722.08 $962,417.48 $658,254.01
Gross loss $(3,557.75) $- $- $(1,175.48) $(2,216.74) $(2,900.25) $(911.19) $(635.62) $- $- $(1,651.80) $(4,139.15)
Total # of trades445246534546424250452446
Percent Profitable979810098979597971001009597
Number winning trades435146524444414150452345
Number losing trades100112110011
Largest winning trade $43,144.62 $129,519.00 $76,802.84 $76,407.91 $102,456.34 $174,605.08 $44,030.54 $64,944.28 $46,922.04 $50,181.30 $123,126.14 $67,489.79
Largest losing trade $(3,557.75) $- $- $(1,175.48) $(2,216.74) $(1,837.00) $(911.19) $(635.62) $- $- $(1,651.80) $(4,139.15)
Average winning trade $11,213.05 $17,420.09 $11,574.26 $14,929.46 $16,292.52 $15,191.67 $10,914.48 $16,149.81 $8,538.36 $13,349.37 $41,844.23 $14,627.86
Average losing trade $(3,557.75) $- $- $(1,175.48) $(2,216.74) $(1,450.12) $(911.19) $(635.62) $- $- $(1,651.80) $(4,139.15)
Ratio avg win/avg loss3.150012.77.3410.4711.9725.40025.333.53
Avg trade (win & loss) $10,877.35 $17,085.09 $11,574.26 $14,625.59 $15,881.20 $14,468.11 $10,632.92 $15,750.16 $8,538.36 $13,349.37 $40,031.90 $14,219.88
Max consec. winners252726242324152328271524
Max consec. losers100111110011
Avg # bars in winners9888999989129
Avg # bars in losers200544260044
Profit factor8300324.01149.5179.4347.18345.6600115.8165.38


Frankly, I was stunned at the accuracy and profitability of these systems - I had been tracking a daily NN model for XIV over the past few months and it delivered as well, but it was long-only and developed only over the past two years. These systems consistently shift from long to short during downturns, and the losses are negligible compared to the gains. Used in parallel, they should provide exceptional returns and high win rates while diversifying your investments across a wide range of uncorrelated assets.

STEP 4: USING LEVERAGED VERSIONS OF THESE ETFS TO FURTHER DRIVE PROFITABILITY

Many of these ETFs have triply leveraged versions (both long and short) that can be used to improve trade returns. The very high win percentages seen in these trades offer a chance to boost profits with not much more risk given the strong historical performance seen in the base ETFs. However, these trades typically last 8-10 weeks and traders need to be careful about longer holds on the 3x variants due to price decay as a result of their daily resets.

By now most folks here have clued into the fact that one can use that very same inherent decay seen in the triply leveraged ETFs as another way to help bolster trade performance. My plan here is to use the long and short signals generated for each unleveraged ETF and short the 3x leveraged ETF variant that will give me the same directional trade.

FXI - a BUY signal would become a short trade on YANG, and a SELL signal would become a short trade on YINN.

GDX - a BUY signal would become a short trade on DUST, and a SELL signal would become a short trade on NUGT.

OIL - a BUY signal would become a short trade on DWT, and a SELL signal would become a short trade on UWT.

RSX - a BUY signal would become a short trade on RUSS, and a SELL signal would become a short trade on RUSL.

SLV - a BUY signal would become a short trade on DSLV, and a SELL signal would become a short trade on USLV.

SMH - a BUY signal would become a short trade on SOXS, and a SELL signal would become a short trade on SOXL.

UNG - a BUY signal would become a short trade on DGAZ, and a SELL signal would become a short trade on UGAZ.

VNQ - a BUY signal would become a short trade on DRV, and a SELL signal would become a short trade on DRN.

XBI - a BUY signal would become a short trade on LABD, and a SELL signal would become a short trade on LABU.

XOP - a BUY signal would become a short trade on DRIP, and a SELL signal would become a short trade on GUSH.

For XIV AND JO, there are currently no leveraged variants, so they are traded as the signals would recommend.

Since the signals are triggered off of completed weekly bars, I only need to run the systems on the weekend and take the trades at the open of the following week (as the system backtests have done). No specific need to be watching daily unless that is something I want to do out of interest or boredom. This simpler signaling system will also help me to achieve my goal of NOT OVERTHINKING THE TRADES (a behavior that probably reduced my profits by half in 2017).

I will post each trade signal here, as well as keep track of how each system does using the "short the 3x" approach. My goal for 2018 is to use only this system and to follow it religiously while sharing the trade signals with others. Most of the systems are currently in a trade long or short - I will post the current trade results this weekend. Some are currently trading at a small loss so there is a chance to get in at a better price than the system did.

I am making this thread read-only so that it acts more like a trading log rather than a discussion thread. I folks have questions reach out to me via email here and I'll try to respond within a day or two (I don't check this one all that often any more).

Merry Christmas - this is my gift to my fellow Stockfetchers, one which hopefully will make everyone some profits in the year to come.

Kevin


Kevin_in_GA
4,599 posts
msg #140347
Ignore Kevin_in_GA
12/23/2017 1:07:06 PM

Here are the current trades for each system, and the new trading signal (BUY/SELL/HOLD) for the coming week.

MODELCURRENT POSITIONENTRY DATETRADE AMT.ENTRY PRICECURRENT PRICEGAIN/LOSS ($)GAIN/LOSS (%)NEW SIGNAL
FXILONG8/14/2017 $20,000.00$42.16$45.98$1,812.149.06%HOLD
GDXSHORT12/4/2017 $20,000.00 $22.26$22.89($566.04)-2.75%HOLD
JOSHORT12/11/2017 $20,000.00 $15.21 $14.95 $341.88 1.74%HOLD
OILNONE- - -$6.28 --BUY
RSXLONG12/11/2017 $20,000.00 $21.72 $21.11 ($561.69)-2.81%HOLD
SLVSHORT12/18/2017 $20,000.00 $15.20 $15.40 ($263.16)-1.30%HOLD
SMHLONG8/21/2017 $20,000.00 $85.65 $99.16 $3,154.70 15.77%HOLD
UNGSHORT12/11/2017 $20,000.00 $5.62 $5.25 $1,316.73 7.05%HOLD
VNQLONG12/18/2017 $20,000.00 $85.26 $81.82 ($806.94)-4.03%HOLD
XBILONG12/18/2017 $20,000.00 $82.29 $84.58 $556.57 2.78%HOLD
XIVLONG12/18/2017 $20,000.00 $135.17 $135.28 $16.28 0.08%HOLD
XOPNONE- --$36.85--HOLD


One new BUY signal for OIL, and several trades that are currently trading at a loss that represent opportunities to get into these trades at a better price.

I will be shorting the triple leveraged variants for each of these trades, taking the opening price on Tuesday for my entries, and track then until the signals indicate to close out the trades.

Kevin_in_GA
4,599 posts
msg #140393
Ignore Kevin_in_GA
12/26/2017 9:50:44 AM

TRADE TRACKING

ETFPOSITIONENTRY DATEENTRY PRICESHARESTRADE SIZE ($)CURRENT PRICEGAIN/LOSS($)GAIN/LOSS (%)
NUGTSHORT12/26/2017$30.5565520,000---
DWTSHORT12/26/2017$15.181,31820,000---
RUSSSHORT12/26/2017$23.0286920,000---
USLVSHORT12/26/2017$10.751,86020,000---
DRVSHORT12/26/2017$10.831,84720,000---
XIVLONG12/26/2017$134.0014920,000---


I will be updating this every weekend with trade data and new signals. I will also be updating the non-leveraged trades as well for comparison - my guess is that the leveraged trades will do much better over time but the drawdowns will be a lot more, so patience is required and trades should only be made based on BUY and SELL signals from the systems.

Kevin_in_GA
4,599 posts
msg #140486
Ignore Kevin_in_GA
12/29/2017 6:58:17 PM

NEURAL NETWORK PERFORMANCE AND SIGNALS FOR 01/02/2018:

MODELCURRENT POSITIONENTRY DATETRADE AMT.ENTRY PRICECURRENT PRICEGAIN/LOSS ($)GAIN/LOSS (%)SIGNAL FOR 01/02/2018
FXILONG8/14/2017$20,000.00 $42.16 $46.17 $1,902.28 9.51%HOLD
GDXSHORT12/4/2017$20,000.00 $22.26 $23.24 ($843.37)-4.22%HOLD
JOSHORT12/11/2017$20,000.00 $15.21 $15.69 $(611.85) -3.06%HOLD
OILLONG12/26/2017$20,000.00 $6.32 $6.54 $696.20 3.48%HOLD
RSXLONG12/11/2017$20,000.00 $21.72 $21.21 ($469.61)-2.35%HOLD
SLVSHORT12/18/2017$20,000.00 $15.20 $15.98 ($976.22)-4.88%HOLD
SMHLONG8/21/2017$20,000.00 $85.65 $97.81 $2,839.46 14.20%HOLD
UNGSHORT12/11/2017$20,000.00 $5.62 $5.83 ($720.41)-3.60%HOLD
VNQLONG12/18/2017$20,000.00 $85.26 $82.98 ($534.83)-2.67%HOLD
XBILONG12/18/2017$20,000.00 $82.29 $84.87 $627.05 3.14%HOLD
XIVLONG12/18/2017$20,000.00 $135.17 $134.44 ($108.01)-0.54%HOLD
XOPNONE---$37.18 --HOLD

HOLD ALL CURRENT POSITIONS. NO NEW TRADES TO BE TAKEN.


Kevin_in_GA
4,599 posts
msg #140488
Ignore Kevin_in_GA
12/29/2017 7:42:01 PM

TRADE TRACKER:

ETFPOSITIONENTRY DATEENTRY PRICESHARESTRADE SIZE ($)CURRENT PRICEGAIN/LOSS($)GAIN/LOSS (%)
NUGTSHORT12/26/2017$30.55 65520,000$31.96($882.35)-4.41%
DWTSHORT12/26/2017$15.18 1,31820,000$14.05$1,608.54 8.04%
RUSSSHORT12/26/2017$23.02 86920,000$23.00$17.39 0.09%
USLVSHORT12/26/2017$10.751,86020,000$11.75($1,702.13)-8.51%
DRVSHORT12/26/2017$10.83 1,84720,000$10.42$786.95 3.93%
XIVLONG12/26/2017$134.00 14920,000$134.44$65.67 0.33%

Neither a good week nor a bad one - net loss of -$106 (-0.09%), entirely due to the big moves in SLV and GLD this week.

Two things to remember:

1. The use of triply leveraged ETFs amplifies any drawdown seen in the underlying ETF. This should drive greater gains over the longer term, but it requires developing a greater tolerance for risk and acceptance of drawdowns during the trade.

2. The average trade duration for these NN systems is nine weeks, not nine days. Patience as these trades develop over time, and the price decay of these 3x ETFs works in our favor over weeks to months. I personally have to adjust to that long a hold time, and to not do any other trading during the week.


StockFetcher Forums · Stock Picks and Trading · THE RISE OF ARTIFICIAL INTELLIGENCE: MY 2018 NEURAL NETWORK TRADING SYSTEMS<< >>Post Follow-up

*** Disclaimer *** StockFetcher.com does not endorse or suggest any of the securities which are returned in any of the searches or filters. They are provided purely for informational and research purposes. StockFetcher.com does not recommend particular securities. StockFetcher.com, Vestyl Software, L.L.C. and involved content providers shall not be liable for any errors or delays in the content, or for any actions taken based on the content.


Copyright 2022 - Vestyl Software L.L.C.Terms of Service | License | Questions or comments? Contact Us
EOD Data sources: DDFPlus & CSI Data Quotes delayed during active market hours. Delay times are at least 15 mins for NASDAQ, 20 mins for NYSE and Amex. Delayed intraday data provided by DDFPlus


This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.