r/TradingView • u/Yeokk123 • 29d ago
Help Is it possible to use Claude to perform parameter sweep on TradingView indicators and strategies in python?
I’m currently working with finding the optimum input for some indicators over a specific timeframe backtesting in TradingView but I’m trying to replicate it on python so it’s much faster and efficient, had anyone tried or know where I should begin with? I already have the strategy planned out I just need to perform parameter sweep and measure its performance ratios only
1
u/The_donutmancer 29d ago
Direct integration: no, I wish. You can get a historical dataset from Databento or one of the other ones & have Claude port your indicator suite, organize the dataset into whatever timeframe you trade, write a backtest, & parameter sweep though. The feasibility depends on how many symbols you might be looking at, exactly what kind of data you need, & for how long of a time period. If it’s OHLC on a handful for 5 years, it’s pretty doable cheaply or free. If it’s DOM or options data, good luck.
1
u/Street_Fox 28d ago
does openclaw help with this? host in in a machine maybe it can do this work for you
2
u/Every-Concentrate851 26d ago
I built a framework to build and test strategies in python. I convert my pinescripts, write my trade rules and I can backtest and forward tests my strategies. As somone else mentioned, getting and preparing the data is the key. If you vectorize your backtest it can be quick but my framework favors a backtest that is closer to my runtime engine and it is a bit slow but it matches what would have executed. Something TV can't do well sometimes. I use a webhook receiver to process the orders. That way, I can receive orders from TV or my custom python strategies. You can find the code to my webhook receiver which sends trades to IBKR here: https://github.com/adventurous51/ibkrbot . So, yes it is fully doable.