Skip to content

Instantly share code, notes, and snippets.

@joelschopp
joelschopp / royalty.py
Created May 5, 2023 19:57
rebalance royalty backtest
import datetime
import backtrader as bt
import backtrader.analyzers as btanalyzers
class Strategy(bt.Strategy):
params = (
("buffer", 0.05),
("threshold", 0.05),
)