stevehopwoodforex.com
https://www.stevehopwoodforex.com/phpBB3/
Print view

Daily Fibonacci Signals
https://www.stevehopwoodforex.com/phpBB3/viewtopic.php?t=4100
Page 9 of 21
Author:  snailbeard [ Sun May 15, 2016 8:25 am ]
Post subject:  Is it the end of the road for EODGT?

A lot of work has gone into EODGT and I was hoping to run it on a range of shares, but so far it seems the number of available/useful shares in Empty4 is restricted. It is really the same problem that we have with currencies when they do not move enough in any particular direction. After the next big crash and rebirth I think this could work quite well. XAUUSD and RioTinto are still doing well with this method but here is an example of the spread to ATR ratio problem with say 3I:
Lets say we find a broker with a a thin spread on 3I then EODGT produces a promising result:
3I-tested-with-Rio-settings-12May16.png
The good news is that by using a different data set for back testing we address the issue of curve fitting. This demonstrates that the method is not to heavily tuned to one particular snap shot of data and shows that we might have a useful tool. However, 3I and other shares (and therefore the corresponding index) are not moving that much in relation to cost of placing a trade.

When I repeat the back test with the spread available from FxPro, The EA just spits out a warning that the spread is too high in relation to the expected daily movement. On the following chart we can see the ask and bid price:
3I-superspread-not worth-day-trading-12May16.png
So just to get in and out of the trade we lose too much of the available range and have too higher risk of hitting a stop loss!

It seems the priority at this stage should be to focus less on tweaking algorithms and instead have a utility which does a daily scan of currencies, indexes and shares and short lists only those assets which are potentially profitable (as a day trade) or look for assets from a weekly perspective.
Author:  snailbeard [ Wed May 25, 2016 9:09 am ]
Post subject:  FBATT - Find Best Assets To Trade

So following on from the previous post, I was wondering what was the best way to go about pre-selecting some currency pairs, indexes or shares to trade. Should it be an EA, an indicator or a script. It is a utility that needs to run and produce an update once per day, at the end of the current trading day. In that respect it needs to be an EA, unless it is run manually to assist with manual trading. Flicking through lots of charts waiting for a set-up can be quite tedious, so what would be the best way to scan all available assets and come up with a short list?

The best trading conditions seem to be quite rare, i.e. there is a steady or growing swing with each new day making higher highs or lower lows with short and mild pull backs. Nevertheless they do occur for each asset from time to time and it would good to be ready when it happens.

The next difficulty is finding a reliable way to measure and quantify any such trend. Traditionally one might use something like ADX to determine the direction and strength of a trend. Experienced traders know that these indicators are all lagging so not much use unless there is a longer period of trending and also slow to react to reversals.

So lets see an example of D1 ADX giving some potentially useful information:
EURGBP-lasting-daily-trend-Oct2015-to-April2016.png
We can see that some of the time the trend is constant and growing, however, on any particular day ADX won't be any use since it will still be going up even if the trend is weakening. We might be able to use this in a similar way to the Currency Strength Indicator just as a rough filter to collect a list of strongly trending assets.

It looks like this will require several layers of filtering and ranking to end up with a short list of best assets to trade. A spread sheet format is a convenient way to rank and re-rank by multiple columns.
For flexibility we could collect a range of metrics in this spread sheet. This unranked data can act as a basis for experimenting with different ways of including and excluding assets from a short list.

The first step is to generate unranked metrics which will look like the following:
FBATT-NothingToTrendTradeToday-24May2016.png
This table is an ADX summary for each available asset in the platform. The 3rd column is the strength of the main ADX line. This is too lagging to be of much use by itself. The next column indicates whether the main line is still going up and for all pairs the condition is false, meaning that all assets are pulling back, nearing the end of a trend, ranging or reversing. This does not necessarily mean that we don't have any usable trends but we might have to look at a faster time frame to see them - could we apply the same measurements on H4?

However, since we have metrics for the close of 23May2016 we can use hind sight to evaluate the strengths and weaknesses of this approach. We can now look back at the 24May2016 and ask whether or not this table could help us decide what to trade and how to trade. So the table indicates that nothing in the list is strongly trending. Therefore, we can sit on our hands or consider a different approach. Since the table is agnostic does it mean we can trade in any direction? Could we use a range trading method? Could we look for a breakout with momentum?
What actually happened on the 24May2016 for EURCAD? The following chart shows how several days before the 24th were slow pull-back days but the 24th itself followed the longer term sell trend:
EURCAD-D1-ADX-says-sell-but-has-weakened-24May2016.png
ADX is more sell than buy and the up bars are diminutive, indicating that this is more of a pull back than a reversal. However, it seems that the table indicates that we are at the end of a trend rather than in the middle of one, so perhaps there is more scope with indexes or shares?
The following chart shows that the ADX has strong buy momentum and it also turned out to be a good trading day for Barclays:
Barclays-D1-strong-ADX-momentum-24May2016.png
So Barclays would apparently have been ranked at the top had we included it in the scan.
Should we include different asset classes in the same table or use separate tables for each asset type allowing us to pick the best from each category?
Why does EURCAD give an agnostic Buy/Sell reading when it is more sell than buy?
I hope to answer these questions after more testing.
Author:  snailbeard [ Sun May 29, 2016 6:36 am ]
Post subject:  More assets to trade

After a lot work to cope with the differences in pip, ticks, digits, lots and broker specific names, it is now possible to switch between, forex, indexes and shares. It is more straight forward to process each type of FI separately.
So if most forex pairs are treading water is it possible to find a healthily trending stock index? Probably not at the moment, but here is an example of a snap shot from early February 2016:
FBATT-Euro50-hint-of-a-trend-Feb2016.png
The first step is to sort the rows so that assets with higher spreads in relation to the daily range are at the bottom. The remaining indexes are not that trendy according to the ADX main value. Since we don't have anything of strong interest we could look at Euro50 which indicates a preference for long term selling and in addition the two ROC fields are true indicating the possibility of some price action.

How reliable are these FBATT hints? Can they be used to help choose a particular method of trading?
Below is the chart for Euro50 over several months:
EuroStock50-2week-cycle-Jan-Mar2016.png
With the benefit of hindsight we can see that there is about a weeks worth of usable price action each month before prices reverse up. Do we have any entry methods which can work well with this type of price behaviour? Or should be patient and continue looking for something more trendy?
Author:  snailbeard [ Sun May 29, 2016 8:03 am ]
Post subject:  FBATT - Find Best Assets To Trade

FBATT currently runs as a script since its purpose is to provide an end of day summary of prospects for the following day or coming week. This makes it difficult to test past dates, especially as it shares a lot of code which is common to other EAs. In the end I added a runtime user parameter which can shift the day of PERIOD_D1 analysis, but not the higher time frames, which means I can run it 'live' for a particular back date.

So now there are two ways of running with a past date:
A) Single asset mode, with multiple past dates
B) Basket mode - a single past date but for multiple assets

This turned out to be quite a lot of work as I had to retrofit a lot of changes to shared code to work in such a flexible way, but the philosophy is to have one body of code to maintain rather producing several specialized variations to keep track of.

The back date approach means I can manually scan through daily charts and pick a few dates to test and then check that FBATT produces results consistent with those dates.
The following is for EURGBP:
FBATT-EURGBP-with-added-MA20&60.png
So According these results EURGBP was more trendy (and therefore a better prospect) than it is currently:
Firstly, there is a stronger ADX main (but not much use by itself as it is too lagging), next both ROC readings are true, then AD+/- is BUY and the MA20/60 is consistent with Buying.
The second more recent reading is not as interesting, with a weaker ADX readings, but -Ma20/60 suggests there is some downward slope and perhaps action on a faster time frame.

So is the first reading consistent with the actual price movement for early January?
EURGBP-lasting-daily-trend-Oct2015-to-April2016.png
We can see that the first reading of good long term upward trend is correct.
However, this is meant to produce a sorted hot list, so does work for multiple assets?
In the following table I have run the script for the most popular pairs and manually sorted the rows:
FBATT-deeper-inspection-top-pairs-2016-01-08.png
We see that I have relegated a number of pairs to the bottom because they have higher spreads.
I've also relegated EURUSD, EURJPY because the ADX readings are weaker.
There are five pairs at the top of the hot list.
However, GBPJPY, GBPUSD and EURGBP are correlated so it would be better to pick the best of the three.
The next pairs are interesting (USDCAD and USDJPY) because if we trade both of them (BUY, SELL) then we eliminate the USD and are essentially trading CADJPY but with better spreads! Note that CADJPY would be high in the short-list if it had a smaller spread.

So this approach reduces to a short-list to 3 pairs, but essential two trades, and we can ignore the other pairs and focus our attention on the short list.
At least that is the theory but would it work in practice?
It doesn't take long to sort the list but it would be good if it was automated.
However, it would be better to spend that time catching good trades...
Author:  snailbeard [ Mon May 30, 2016 5:45 am ]
Post subject:  CADJPY spread and swap costs

Following on from the previous post, we saw that CADJPY was strongly trending on the 8th January 2016, but the spread was too high. In addition to the high spread we need to take into account the swap because we might hold the trade for several days, we might even be willing hold over weekends, and perhaps even longer. Maximum profit is possible by holding and re-entering during long trends, provided that we have the right combination parameters.
In the following we can see that CADJPY had strong momentum but also a much higher swap cost for selling:
CADJPY-D1-strong-trend-but-expensive-8Jan2016.png
Author:  snailbeard [ Tue Jun 07, 2016 6:05 am ]
Post subject:  More assets to trade

Running FBATT on forex, popular indexes and popular shares doesn't currently show much in the way of useful trends, so I thought it might be a good time to add some Agri-Futures into the mix. Brokers often make up their own prefixes and suffixes for these, so it might be a headache to run this on other brokers platforms.

It would be interesting to know what percentage of this forums members trade other assets besides forex. I would prefer to just trade forex if they were more trending, because there would less chance of getting the digits, price range and lot sizes mixed up. I believe that most of the bugs relating to these calculations have been fixed but more testing is required...

The current ATR limitation is less relevant to Futures which have high entry costs and need to be run for at least a few weeks to be cost effective. This means that any prioritising of futures should be based more on the quality of the trend.

According to the following table interesting things have been happening for sugar and corn. Now, why am I thinking of popcorn and is there a connection?
AgriFutures-FBATT-sugar-06June2016.png
It seems I've been asleep at the wheel and missed some good opportunities. However, just because there is a trend doesn't necessarily mean that this is low hanging fruit. I suspect my current entry and exit methods won't do very well on these slow moving assets.

The following chart looks like any other asset that goes into a strong trend:
Corn_N6-breakout-long-March-to-June2016.png
However, unlike the convenience of currencies with their thin spreads and 24 hour access, Futures have two or three sets of time restrictions and fat spreads. Should we buy on Mondays and hold to Friday? Or buy at the beginning of the month and sell at the end? Or buy little lots every day?
Author:  snailbeard [ Sat Jun 11, 2016 7:08 am ]
Post subject:  Forex, scraping the barrel

If you are successfully range trading currencies then something like FBATT would not be of interest. Especially, as currencies often have weak trends for long periods, interspersed with the occasional stronger trends.

Looking back at the start of April 2016 an FBATT overview is not that interesting, we have to ignore the main ADX value to find a single pair of interest, which is USDJPY:
FBATT-slow-AdxMain-forex-for-01Apr2016.png
In steady trends the ADX strength remains high but in weak-trends, due to the lagging issue, we can miss out on several days of hot price action. However, when there is nothing else on the radar, we can take an interest in the ROC (rate of change) which is hot for USDJPY, in addition to ADX Minus and the long term MAs. The spread value is high because this was a back-shifted test run at the weekend.

Looking at the chart for USDJPY we can see how the opportunity to sell unfolds:
USDJPY-D1-slow-AdxMain-05Apr2016.png
So if using FBATT doesn't highlight any strong trends and we are scraping the barrel for strong price action then we can sometimes ignore ADX Main and find a few good days of safer trading (or an emerging trend).
Author:  snailbeard [ Sun Jun 12, 2016 7:37 am ]
Post subject:  Swiss cheese and CrappyTester

A sigh of exasperation is what you'll often hear from those of us who persist with using MetaQuotes CrappyTester. Many people in this forum have long abandoned the effort of trying to get meaningful results out of it.

However, if I didn't use it then I wouldn't know for several years all the bugs and incorrect assumptions that would slowly slowly pop-up just when I had convinced myself that I a great tool.

Of course it isn't all down to CrappyTester, its also the headache of trading more than one asset which compounds the headache into a migraine of collecting and managing all that data.

So if you can find just one asset to regularly trade successfully that would be great. However, as far as I can tell, all currencies have long stretches chaotic price movements between good well defined ranging or trending.

I had a brief look at the TradeStation web site and wondered if this would be a way to get instant access to good data and meaningful testing, instead of spending every spare minute trying work around MetaQuirks

For example, how about this one:

Sunday/Monday day boundary issue:

M1 : Bad (0/1:) 0: 2015.02.01 23:00
M5 : Bad (0/1:) 1: 1970.01.01 00:00
M15: Bad (0/1:) 1: 1970.01.01 00:00
M30: Bad (0/1:) 1: 1970.01.01 00:00
H1 : Bad (0/1:) 0: 2015.02.01 23:00
H4 : Bad (0/1:) 0: 1970.01.01 00:00
D1 : Bad (0/1:) 1: 1970.01.01 00:00
W1 : Bad (0/1:) 0: 1970.01.01 00:00

Another start of day, missing minutes quirk:

M1 : Bad (0/1:) 0: 2015.07.01 00:45
M5 : Bad (0/1:) 0: 2015.07.01 00:45
M15: Bad (0/1:) 0: 2015.07.01 00:45
M30: Bad (0/1:) 1: 2015.07.01 00:30
H1 : Bad (0/1:) 1: 2015.07.01 00:00
H4 : Bad (0/1:) 0: 2015.07.01 00:00
D1 : Bad (0/1:) 0: 2015.07.01 00:45
W1 : Bad (0/1:) 0: 2015.06.25 00:00

Note that D1 can sometimes start at 00:xx instead of 00:00
whereas H1 and H4 start at 00:00

should D1 be rounded to 00:00?

Multi-timeframe EAs need to be able work around all these issues. However, when back testing it is so easy to end up testing where there are big holes in the data of a particular time frame, but it can be problematic to distinguish between the typical smaller holes and the big ones!
Author:  snailbeard [ Fri Jul 22, 2016 2:05 pm ]
Post subject:  Why auto-traders ultimately fail

The summer holidays are drawing to a close for us but perhaps you are just starting yours?
So were you brave enough to trade through the Brexit volatility? We turned off our computers and flew off to California. It was a surprise that enough people had the courage to choose uncertainty, just after the result it seemed like there was going to be a student uprising/coup and we would be stuck in a terminal just like Tom Hanks.

Well its back to the charts and what would have happened if I'd left Gold-EODGT running through the Brexit period, and the only way for me to find out is to use our favourite back-testing tool CrappyTester. According to Crappytester it would have had three losses and one win, but was it a volatility issue, an expected variation in profits, a bug, bad data or an algorithmic issue?

First impressions:

Looking at the first loss on 13/14Jun14 which occurred about a week before Brexit, we might expect a flight to Gold from some traders/investors. However, the following daily chart doesn't support any indication of panic buying prior to Brexit. Perhaps most traders/investors expected a no change vote?
gold-d1-falling-ATR-Mar-Jun2016.png
From the above the Yellow 14-day ATR shows a general falling of price movement, which by itself might be enough reason to turn off trading. It is also apparent that price is between two converging long term moving averages (an indication of ranging).
So caution is advised, however, on 13 June there were a series of bars moving with strong upward momentum, in the context of monthly ranging.

My first thoughts are that we can expect more failures due to the falling ATR, but there could be other reasons as well...

The following chart showing M15 Bars gives a more detailed view of entry and exit timing:
gold-m15-buy-missed-by-a-whisker-13Jun16.png
Looking only at price action between A, B and C, the actual entry did not occur until price reached 1281.22.
In my view this counts as a late entry and the question is why did we not get a better entry price such as 1276.99. There are a number of MAs on this chart showing upward momentum, although we can see a strong price reversal back to the purple MA in the early morning, later this MA is providing support. (I don't have any code that can give me a true or false flag that a MA is providing support, but I can infer visually that a break-out (or break-away) from this MA could be a entry signal.

However, break-outs can be spotted in other ways but the market-movers are also expecting to catch the break-out traders with sharp price reversals, so it is no good claiming that we can make a successful earlier entry only to be stopped out (and suggestions of increasing stop distances are not welcome).
Before looking in detail at the false break-out issue lets consider a better entry point based on today's current M15 close price being higher than yesterday's close price, this simple trigger when combined with other logic is an effective entry method, however, by itself it is good for feeding the sharks. In the following M1 chart you can see the little fishes taking the bate and then being swallowed by the sharks, and also later how some experienced traders trade break-outs later in the morning (but how do they know it is safe?):
Gold-M1-avoiding-false-break-outs-13Jun2016.png
We can see that B1, V1 (the first series of break-outs) are lacking in momentum, whereas B2, V2 show price action combined with increasing OBV.

So now we have a theory about getting a better entry, but I have not shown why the current late entry was late, but it always comes down the same issue, which is the lagging nature of higher time frame indicators or pattern matching. The trend-trading entry of EODGT can't place entries until the slower indicators confirm that the trend is still a trend - it seems obvious to us from the chart but each way of identifying a trend has it's weaknesses. The issue in this case is to do with H4 which does not begin at 00:00 but 01:00 delay the output by an additional hour as can be seen on the following chart:
gold-h1-h4-delayed-start-affects-H4-properties-13Jun2016.png
So to answer the question: 'why do auto-traders ultimately fail?' in this particular case we are applying code originally designed for 24H data and trying to use it for something which trades for 22H per day, which means the H4 time-frame can give spurious results.

So on the one hand if we are not short of other assets to trade then we can simply use the falling ATR to filter out weakening trends, but if we are struggling to find something to trade can we speed up the entry by adding an additional trend confirmation computation?
My view is that we should not fall into that trap, the system works well in good trading conditions despite the 22H issue. Not only do we have the the longer term falling ATR hint but we have several long tailed H4 bars warning us of excessive price swings confirming that we should not try to take day trades.
We can stop our auto-trader from failing by detecting poor trading conditions and inhibiting trading.

Of course the weak trends were only traded because I had forgotten to turn on the FBATT filter, if I rerun the back-test with FBATT filtering then those failing trades disappear!
Author:  snailbeard [ Sun Aug 14, 2016 7:20 am ]
Post subject:  M1 breakout signals

Since my last post I have been experimenting with breakouts based on the M1timeframe. One option is to use growing M1 momentum as an input to manual trading. Generally, M1 can result in a lot of false breakouts, but it can also be a way to avoid being late into a trade. Traders who can't sit around flipping through charts need a ping on their mobile phone when something interesting is happening. This approach won't be much use if there are too many alerts or too few. The following chart shows three potential alerts:
gold-m1-selecting-a breakout-threshold-20July2016.png
The blue rectangle and the slow moving averages help to identify growing price action in a particular direction.
The longer we wait and see where price action is going the more confident we are about today's sentiment, but if we wait too long to enter, we might not be able to reach a satisfactory profit target before a major reversal or we may get caught by a reversal which is greater than our stop-loss.

The potential alerts at A, B, and C allow us to vary our entry point, we could vary our threshold according to the pair and market conditions. I haven't currently coded this collection, but noticed that the methods I have already implemented missed this perfect day, even though some erratic days get signals.

The basis of signal selection is partly on price movement and partly on how long it has been since price was previously at this level. i.e. Higher highs or lower lows.
All times are UTC Page 9 of 21