SAP L Portfolio (Small Account Portfolio L size) is a comprehensive solution for traders with smaller trading accounts, looking for stable and consistent returns. It includes various types of strategies such as reversal, bias, momentum, and trend to provide a diversified approach to investing.

# Before you start

Are you browsing portfolios for the first time? Be sure to read our __article__ dedicated to portfolio creation.

# Strategies in the SAP L portfolio

# Assumptions

Account size - for basic testing

**I used a $20k account**(MM$), margin (x2) is occasionally utilized.Strategies used in the portfolio are tested with MM$ according to the table below, for example, the Triple B strategy has a constant allocation of $7000 throughout the entire 30-year period.

Strategy tests are conducted for the period 01.1994-05.2024, except for instruments that do not have such distant historical data where the maximum available historical period is considered.

The creation of the strategy portfolio using MM$ was done in Strategy Quant.

Strategies were tested on default instruments (Primary Instrument) indicated in the Recommended Instrument section in the strategy descriptions. For most Stockpicker strategies, these are S&P500 stocks.

Transaction costs and slippage were taken into account in the tests, following a study for the Alpaca broker (see our detailed study).

# Strategy in the portfolio vs. capital allocation

*Source: Extract from Portfolio Summary spreadsheet*

# Max Drawdown as a starting point

The starting point when constructing a portfolio, in addition to selecting very good and low-correlated strategies, is the maximum acceptable drawdown for the entire portfolio. In the case of the above portfolio settings, it was 19%.

# Historical exposure

Another key factor that I take into account when constructing a portfolio is how the account will be used over time. The exposure over a 30-year period for the above portfolio looks as follows:

*Source: *__Exposure Master__

The capital allocated to individual strategies in the backtest is indicated in the table in the MM$ column. The combined settings of the strategies result in a theoretical maximum exposure of 195%, but as shown in the chart, the average exposure was $15.7k (78% of the account).

For about 20% of the time, this exposure utilized margin, but only for 5% of the time did it exceed a total of $24.5k. The maximum historical exposure of $34k never fully utilized the x2 margin level.

# Backtest MM$

In this backtest, each strategy has a fixed capital to trade with throughout the entire testing period (in accordance with the table above).

This backtest does not take compounding percentage into account.

The goal of the test is to determine:

What was the maximum historical drawdown expressed in $ in the portfolio.

What monetary results can we expect by using such a portfolio from the very beginning (before we feel the effects of compounding percentage).

What are the basic parameters of the tested portfolio.

Here is the Equity chart of the portfolio from this test:

The chart also shows the share of individual strategies within the portfolio.

Basic test parameters are marked in green:

Financial results month by month and year by year:

Additional information about the results:

# Correlation

The correlation test is conducted on the same period of data for all strategies (2004-05.2024). Below are the correlation results for the portfolio:

Correlation by DAY:

Correlation by WEEK:

Correlation by MONTH:

The two strategies Triple B and RSI Range Rider show increased correlation, especially in the monthly interval. However, if we only compare the losses of both strategies, the correlation looks much more favorable*.

It follows that the two strategies regularly had profits in the same periods. In trading, the goal is for losses not to be correlated - high correlation of profits is acceptable to me.

**Correlation by Loss is correcty counted using SQX v140 or above, due to the bug in previous versions.*

You can read more about correlations __here__.

# Pattern Day Trading

A test was conducted for the entire portfolio to check for the occurrence of a Pattern Day Trading. It showed 97 occurrences over 30 years of history and over 35'000 transactions. This means that on average, such a pattern could occur about 3 times a year. Because there are systemic protections on the broker side Alpaca and proper management of such positions by Algocloud, we believe it is acceptable that in these rare cases, an excess Daytrade may not be closed on the same day but on the next day when the conditions are met. If you have an account below $25k and would like to use this portfolio, it is important to understand how PDT works. You can read more about it __here__.

Test details:

# Max Trade Value

For smaller accounts, it is important to pay attention to the Max Trade Value column (capital distribution table among strategies above). For example, in the Turtle Trend strategy, the value is $200. This means that the Stockpicker mechanism in Algocloud will only open positions on stocks valued below $200 (insufficient allocated capital prevents it from buying stocks with a higher value). In other words, if the unit price of a stock is, for example, $45, Stockpicker will buy 4 shares. If the price is $220, it will not buy any. If your account is below $20k, the values in the table will decrease proportionally, so conduct your own calculations in this range. This behavior is normal and is accounted for in the backtest. You can manage this by reducing the Max Open Position value in the Position Score tab, for example, from 20 to 15. However, please conduct appropriate tests after making such a change.

# In-depth analysis of results

The following estimations were made in a dedicated Excel spreadsheet (Portfolio Summary). Monthly results from SQX were copied into this spreadsheet as a basis for further calculations.

The strategy portfolio generated an average annual return of 24%, which is significantly better than the benchmark (SPY) with a CAGR of approximately 10.4% during the same period. A key feature of the portfolio is that during very difficult periods for the stock market (highlighted in yellow), the portfolio also generated an average return of around 20%. Even in the last bear market in 2022, the return generated was around 30%!

Here are the returns in percentage, month by month and year by year:

# Compound interest

The use of compound interest magic is the essence of investing and trading. It is also an excellent feature and setting that we default to when trading in Algocloud. In backtesting for a single strategy, compound interest is very well displayed in Strategy Quant. Unfortunately, at the level of combining strategies in a portfolio, a reliable test using MM% is not currently possible. Fortunately, it is easy to conduct your own estimation of compound interest behavior based on data copied from SQX with MM$ in our Portfolio Summary spreadsheet.

Here are the results of compound interest for the discussed portfolio:

And Equity chart for this test:

Investing $20k over the years has turned into $24M, all thanks to strategies that allowed for stable compound percentage growth.

The above estimates used the method of compound interest in monthly cycles. In actual trading on Algocloud, interest is calculated in daily cycles. Each strategy opens new positions every day based on the current account value, i.e. the total capital generated by all strategies. According to our estimates, the daily method should additionally have a positive impact on the long-term results of the portfolio, although it may not be the case in every situation. We hope that future versions of SQX will also allow us to calculate and present such results.

# Summary

## Strengths of the portfolio

The foundation of the portfolio consists of very robust reversal strategies, which have proven their quality with a huge number of transactions in backtests.

The presented portfolio turned $20'000 into over $24'000,000 over 30 years, achieving an average annual return of 24%, which is significantly better than the benchmark (around 10.5%).

The portfolio did not have a single losing year, and despite being Long Only, it performed only slightly worse during bear markets.

There is a high win rate (67%), which is the driving force of the portfolio and compensates for the fact that the average loss is slightly larger than the average gain.

The portfolio is suitable for accounts with capital below $25'000, as originally intended.

## Weaknesses of the portfolio

One limitation could be the increased correlation between two strategies (Triple B and RSI Range Rider). Yet, these strategies have distinct characteristics: Triple B is quicker, while RSI Range Rider catches longer moves. This actually works to their advantage. When you look at how they correlate by losses, the picture is more positive, even monthly. That's why we've decided to include both in the portfolio.

The strategies included in the portfolio are consistent with the long-term characteristics of the stock market. Reversal strategies dominate, balanced by strategies utilizing Momentum, Trend, and Bias.

A maximum drawdown of 19% is, in our opinion, an acceptable proportion compared to the profits achieved and the fact that the market plunged by over 55% in the same periods.

Over 35'000 trades in the strategy portfolio confirm the robustness of the strategies applied in very different market conditions that we have experienced over the past 30 years.

# How much do the strategies from this portfolio cost?

PRO strategies on Algohub are available for purchase individually or in the form of sets/portfolios.

**What you receive with your purchase**

For the portfolio:

Portfolio Summary Sheet

Portfolio SQX file

For each strategy included in the portfolio:

E-book detailing the specific rules and results of the strategy.

SQX file ready to use on platforms such as Algocloud and StrategyQuant.

Pseudocode describing all rules in an easy-to-understand manner.

### Disclaimer

The results obtained from historical data do not guarantee future outcomes. The effectiveness of a strategy can change over time. Backtesting is a tool that allows for the analysis and evaluation of an investment strategy based on historical data. Various factors, such as market changes or economic conditions, can influence the effectiveness of a strategy over time.

Investing always involves risk. This material is not investment advice. We share our experience and algorithms for educational purposes. We make efforts to ensure that our algorithms are error-free, but neither we nor the tools we use guarantee the absence of technical issues. Any decisions to use a particular strategy are made at your own risk and should be preceded by careful understanding and verification. You should always carefully consider your investment goals and risk tolerance before making investment decisions.