Scottfree Analytics combines the power of machine learning with financial data from IEX Cloud to help investors work smarter, not harder.
Introducing Scottfree Analytics and AlphaPy
Scottfree Analytics LLC is a creator of prediction algorithms for finance and gaming. Its mission is to develop advanced machine learning software for trading market strategies. Currently, we have an open-source product AlphaPy that leverages IEX Cloud for both real-time* and historical data.
AlphaPy is a machine learning framework for both speculators and data scientists. It’s written in Python mainly with the scikit-learn and pandas libraries, as well as many other helpful packages for feature engineering and visualization.
Here are just some of the things you can do with AlphaPy:
- Run machine learning models using scikit-learn, Keras, xgboost, LightGBM, and CatBoost.
- Generate blended or stacked ensembles.
- Create models for analyzing the markets with MarketFlow.
- Predict sporting events with SportFlow.
- Develop trading systems and analyze portfolios using MarketFlow and Quantopian's pyfolio.
Applying Machine Learning to the World of Investing
Many traders spend their lives chasing the Holy Grail: a system that will make them rich simply by detecting common patterns and executing trades just by following a special recipe. Technical analysis often produces visually appealing charts, but there isn’t always statistical evidence that all the techniques actually work.
Once you conclude that there is no master algorithm, then you can move to the next level. Collectively, technical analysis is really just an infinite set of features to use in training machine learning models. Scottfree’s perspective is that all the systems you need have already been invented. It applies machine learning to decide which is the best system to trade with at any given moment.
Once the model is trained, all the trading signals are automatically generated, along with portfolio performance.
One system in action: This graph shows the top five drawdown periods, i.e., the amount of time it takes for a new portfolio high to be attained. For example, the top drawdown period lasted from mid-February 2020 to nearly the beginning of May 2020, when the portfolio rose to a new high.
Another system in action: This graph is called an underwater plot because it shows the percentage decline in a portfolio over time. Here, the portfolio declined approximately 8% at its low before recovering to a new high, as shown in the first plot.
Feeding the Machine with a Financial Data Source
To ensure model continuity, there are two important components:
- Model Training with access to historical financial data with depth,
- Model Prediction (Scoring) that depends on continuous and reliable real-time data.
The challenge was to find a financial data platform that delivered on both promises, as we frequently had to switch providers because of consistency and latency issues. Since we maintain an open-source repo on GitHub, we searched for data sources and found IEX Cloud’s iexfinance package, created by Addison Lynch.
While many users integrate using the IEX Cloud API directly, the community creates and supports a range of third-party libraries, one of which is iexfinance. The migration to IEX Cloud was seamless because of three major factors:
- The API is clearly and fully documented.
- Free unlimited sandbox testing Deprecated made it easy for us to experiment with the API.
- With IEX Cloud, we can manage our plan all within a single subscription, rather than purchasing multiple plans at once.
For Scottfree Analytics, it was helpful to explore the IEX Cloud API by beginning with sandbox testing as provided in the API Docs. These sandbox endpoints return free testing data and are well suited for a Python starter program or some sort of sample project.
Eventually, you’ll want to abstract your starter code into a data management module like Scottfree did with AlphaPy here. Make sure that your API Token is configurable and not embedded in the code itself; you can find an example here.
Up Next from AlphaPy
As IEX Cloud expands into more instruments and adds new datasets, the plan is to also expand the capabilities of AlphaPy. Scottfree already aims to develop trading systems with machine learning for:
- Forex and currencies
Scottfree Analytics is also developing an open-source language for feature engineering, where the trader will be able to define and compare market variables across all time frames. We resample the IEX Cloud data using “pandas” time series offsets and then apply AutoML (Automated Machine Learning) to discover the best trading models.
In the past, we always had to cross our fingers, hoping that our pipeline passed the data collection stage. We can now focus on building and maintaining the models themselves, as IEX Cloud has become an invaluable and trusted partner.
Marc Conway is the Lead Data Scientist for Scottfree Analytics and a contributor to AlphaPy. You can reach Robert or Marc at email@example.com or telephone (567) 698-3889.
Scottfree Analytics was founded by Robert D. Scott II.
Find them on LinkedIn:
Robert D. Scott II
*Real-time stock data from IEX Cloud is different from real-time data available via direct connection from IEX Exchange. Learn more.
IEX Cloud Services LLC makes no promises or guarantees herein regarding results from particular products and services, and neither the information, nor any opinion expressed here, constitutes a solicitation or offer to buy or sell any securities or provide any investment advice or service.
Building with Financial Data Sets and APIs
In this article, you'll learn how to incorporate financial data into your application. First, you'll learn more about how to plan for and use real-time financial data in your applications. Then, you'll use the financial API provided by IEX Cloud's Apperate platform to build a financial stock website using NestJS.
Taming the Chaos: Sourcing Financial Data from Multiple Providers
Combining multiple data sources can help your app or website stand apart from the pack. However, it also comes with several challenges. This guide can get you started on the right foot.
12 Questions to Ask Your Financial Data Provider Before You Launch Your App
Creating a fintech app or website that uses financial data? Need a stock market API? Before jumping in, you need to know what you're getting into with your financial data or stock market data provider. We've put together a list of 12 questions to help you navigate potential challenges and identify key success factors.