Saeed Amen of Cuemacro on FX, Alternative Data, and Backtesting

Saeed AmenSaeed Amen is the founder of Cuemacro. Over the past decade, Saeed Amen has developed systematic trading strategies at major investment banks including Lehman Brothers and Nomura. He is also the author of Trading Thalesians: What the ancient world can teach us about trading today (Palgrave Macmillan). Through Cuemacro, he now consults and publishes research for clients in the area of systematic trading. He has developed many popular open source Python libraries including finmarketpy. His clients have included major quant funds and data companies such as Bloomberg. He has presented his work at many conferences and institutions which include the IMF, Bank of England and Federal Reserve Board. He is also a co-founder of the Thalesians.

Grace: Can you tell us how you got started trading?

Saeed: Well I suppose I started around 2005. I’d been studying math and computer science at the Imperial College London and I wanted to do something mathematical that also involved a bit of trading. I started looking at Lehman Brothers that year and I kind of fell into the role of developing trading strategies there within the FX team.

Liza: What led you to choose the FX market?

Saeed: I’ve always been interested in understanding what’s going on globally and trying to understand how people trade in that respect. It’s an interesting market because you’re trying to understand different economies in different countries so it’s something very different to trading say single stocks where you have to drill down individual companies. It’s more about understanding the big picture, which appealed to me.

Grace: Cuemacro is focused on reading cues in the macro markets. What inspired you to start your company?

Saeed: I’ve always been interested in FX markets and growth markets. I wanted to continue what I was doing in banking but I wanted an entrepreneurial edge to it. So now I have more freedom in terms of what types of projects I do and the types of clients I approach. It was me putting an entrepreneurial spin on what I’d been doing for a while.

 Grace: You’ve recently mentioned that there is a lot of room for further adoption of data in trading. How specifically can a trader go about this?

Saeed: The main data you would use in trading is price data so you might look at the chart or at data trends or at price action. Then you might look at other markets as well, for example relating to the FX market you might look at the rates market or at the commodities market. But other than that I think there are a lot of alternative types of data that are coming to the forefront that you could look at as well. You might want to look at flow data from FX trading firms, or you might want to look at a news data. My goal is to try to understand how news datasets work and how they can be used to trade FX. I have done a lot of work around news data particularly but I’m hoping to do more work around flow data and the like in the coming months.

Liza: What’s been your experience in finding alternative data sources like the ones you were just talking about?

Saeed: I think it takes time because you need to have a hypothesis. For example if you’re trying to look at news you’ll first want to come up with an idea of how you’ll use it. Then you go find your data source and do your research and it might take a few months to develop a trading strategy. In every case I always try to start from an idea and then from the idea try and find the data and then do the quantitative research.

“I always try to start from an idea and then from the idea try and find the data and then do the quantitative research.”

Liza: What kind of alternative data sources do you think would be appealing for somebody to start with?

Saeed: Well one interesting thing to start with is social media data which you can get for free (in a limited amount) from Twitter for example. There are also other interesting sources in terms of flow data and potentially news data, but you’d need to think carefully about how you’d use that.

Grace: When it comes to alternative data what do you think traders struggle with the most?

Saeed: The biggest struggle is finding a data source that has data in a clean format. One of the issues, especially if you’re trying to collect alternative data yourself from various websites, is that it tends to be quite messy and you have to spend a lot of time putting it into a usable format. However if you get a dataset that’s already cleaned up and structured, it makes your life a lot easier so you can concentrate more on building the trading strategy as opposed to cleaning up the data.

Grace: Along the lines of alternative data, what do you think about a system reading headlines and using the headlines to make trading decisions?

Saeed: I think that actually looking at individual headlines is one application of reading news data. The difficulty there though, I think, is on training the system to recognize what are market moving headlines and which headlines are not particularly important. Typically the approach I’ve used to reading the data actually is trying to aggregate many articles over a whole day to understand sentiment.  But if you were intraday trading I can see it being quite valuable if you can actually get the computer to understand the headlines.

Grace: What kind of data could a trader look at when trading cryptocurrencies and are there any libraries that you recommend?

Saeed: Crypto data is a lot more freely available than FX data. You can get tick data as well as actual trade data from many different exchanges, and you could even create your own flow data from the trade data. I think one difficulty with cryptocurrency is that the drivers are very different from FX so potentially you might find that sources like social media and Reddit are actually a good place to look for data. There’s not really the case of central bankers impacting the price and the drivers trend to be a lot different.

Liza: What do you think are some of the best ways to use machine learning for trading?

Saeed: I think it’s still the early days for machine learning for trading, but I can see some instances where it could be quite useful. For example let’s say you’re trading at a very high frequency and you have a lot of data – maybe you have the order book data but you don’t really know any sort of patterns with this dataset. Potentially you can try machine learning techniques to identify patterns that may not ordinarily be detected if you were to do it from a traditional approach.  I think one pitfall to machine learning is you may end up fitting up too much noise in the market. You can potentially find noise historically behaves a certain way but you don’t want to use that as a way to form your trades in the future.

Grace: You mentioned that it’s still in the early stages but looking ahead, what do you see on the horizon for machine learning?

Saeed: Another interesting place where you can use machine learning is not so much to come up with trading strategies directly, but essentially to make more sense of unstructured data. So for example if you use something like satellite images to identify economic growth from electricity usage, and you could use machine learning to classify a picture. I think one interesting use of machine learning is not so much purely to come up with a trading but more to understand unstructured data and better ways you could use it, for example in tech to classification of headlines.

“Another interesting place where you can use machine learning is… essentially to make sense of unstructured data”

Liza: Cuemacro seems to focus more on longer term trading. What are some considerations for the FX algo trader when working on longer term strategy?

Saeed: You’re right, I do a lot of long-term trading strategies over days or months, but I also do a lot of intraday trading. I think when you are doing longer-term strategies the considerations typically become slightly different. When you’re doing very short-term trading strategies it could be the case the transaction costs become more of an issue. Typically with longer-term strategies transaction costs are less of an issue, but you may find your risk adjusted returns tend to be slightly lower than those of shorter-term strategies. You have pros and cons to using shorter time horizons vs longer time horizons.

Grace: On your blog you provide advice about creating a system. How do you come up with trading ideas?

Saeed: Typically you would start by thinking about the frequency at which you want to trade, for example either on an intraday basis or more of a daily basis. Then try to come up with a hypothesis about what has influenced FX markets. Typically you will consider macro considerations like what the central bank is doing, what type of flows are going through the markets, perhaps look at commodities as well, etc.  Start with the hypothesis and then you can begin to identify the drivers which might move the market from that perspective. Then once you have that thought process then you actually go away and do your statistical analysis to develop your trading strategy

Liza:  Tell us little bit more about the free resources that you’ve created such as finmarketpy.

Saeed: Finmarketpy is a backtesting library. You can look at historical data and come up with your own trading rules with it and then you can develop a historical backtest from that. There are lots of times when a person has a great idea but when they test it with historical data it actually doesn’t work. That is quite valuable because it potentially saves you a lot of money. On the other side if you find you backtest it and it works historically and you’re happy with it then you potentially take the trade with real cash. Even very experienced traders have lots of ideas and it’s not necessarily the case that all of them will work. The process of research is very important to filter out the bad ideas from the good.

“The process of research is very important to filter out the bad ideas from the good.”

Grace: What are some resources you would recommend to traders that are wanting to study the macro markets?

Trading Thalesians

Saeed: I guess this is a bit of a plug but I have my own book, Trading Thalesians. It’s not so much purely a quant book but it talks about what to look for when you’re trading markets, how to understand the measurement of risk, what you should target when you trade, how to come up with trading ideas, and mixes it with history as well. In terms of other books I like, there’s a really good book by Robert Carver called Systematic Trading that talks about how to develop trend-following strategies. Specifically about FX, there’s quite an old book called Currency Strategies by Callum Henderson and although it’s about ten years old I find it very useful for trying to understand the drivers of currency markets. Then I’d say keep on reading, keep on looking at the Web, keep following finance people on Twitter, and slowly it comes together. The most important thing is talk to your friends, talk to other people in the markets, and share ideas.

Start Algo Trading Today!

Get your free token to connect to the REST API and start trading. To generate your token:

  1. Register for a free practice account here.
  2. Log into and click on the account ID in the upper right corner.
  3. Click token management and generate your token.

Risk Warning: The FXCM Group does not guarantee accuracy and will not accept liability for any loss or damage which arise directly or indirectly from use of or reliance on information contained within the webinars. The FXCM Group may provide general commentary which is not intended as investment advice and must not be construed as such. FX/CFD trading carries a risk of losses in excess of your deposited funds and may not be suitable for all investors. Please ensure that you fully understand the risks involved.