Long Only - Buy And Hold - Manual Universe (free)

Long Only - Buy And Hold - Manual Universe (free)

Here's a FREE ALGO for you, simply hit the CLONE ALGORITHM button below!

This is an implementation of a simple Buy And Hold strategy.

Universe: Manual input of tickers.

Alpha: Go Long at the start of the period and Hold until the end.

Portfolio: Equally Weighted portfolio (investing the same amounts in each security).

Execution: Immediate Execution with Market Orders.

Ideas to try (user-defined inputs in the main.py script):

  • Play with the SetStartDate and SetEndDate dates to change the period of backtest.
  • Add/change the tickers. For example, to select the FANG stocks simply change this line of code tickers = ['FB', 'AMZN', 'NFLX', 'GOOG']
  • Activate the rebalancing mechanism to ensure the portfolio goes back to equal weighting every so often. The rebalancingParam is set to False by default, but it can be set to a discretionary number of days to rebalance the portfolio. For instance, if you want to rebalance every 30 days simply do rebalancingParam = 30
Do you have a strategy of your own that you would like to backtest and automate? Learn about our consulting services and get in touch at admin@innoquantivity.com

    Found this product useful? You can support this site by making a donation using the link below!