Gromo Zeka
Articles by Gromo Zeka on AlgoTradingLib.
Exchanges and platforms
-
Best crypto exchanges in 2026 for spot trading and APIs
Compare Kraken Pro, Coinbase Advanced, Binance Spot and OKX by spot fees, public market data and API testing environments.
-
Kraken Pro vs Coinbase Advanced for BTC/USD
Compare equivalent BTC/USD order books and include spread, depth and each account’s fees.
-
Binance Spot Testnet vs OKX Demo Trading
Compare spot API sandboxes and reproduce the BTC/USDT instrument rule check.
-
MetaTrader 5 vs cTrader for automated strategies
Compare Expert Advisors and cBots and align data, lots, spreads and execution for an honest test.
-
Algorithmic trading platforms by market
Shortlist a platform for crypto, equities or broker FX and validate data and execution before migrating.
-
Compare the cost of the same fill across exchanges
Use a shared benchmark price, account fees and simulated fills to compare one order in basis points.
Market data
-
Download Kraken OHLCV candles to CSV
Export closed BTC/USD or ETH/USD candles as UTF-8 CSV with UTC times and validate the result.
-
Find missing candles in OHLCV history
Detect gaps and duplicates in UTC candle data before calculating indicators or returns.
-
Build hourly OHLCV from one-minute candles
Aggregate closed minutes with UTC boundaries and handle incomplete hours explicitly.
-
Why CoinGecko prices differ from exchange tickers
Tell an aggregated reference price, last trade, displayed quotes and candle closes apart.
-
Rebuild an order book from a snapshot and updates
Apply absolute level changes in order and validate the book before exposing it to a strategy.
-
Measure market-data latency and coverage
Design a timestamped observation run that distinguishes delay, local queue time and missing events.
Technical indicators
-
StochRSI with 7, 14 and 28-bar lookbacks
Change the lookback on a BTC/USD chart while holding the RSI period fixed.
-
SMA vs EMA on the same price chart
Compare equal-length simple and exponential moving averages and see where their responses differ.
-
Wilder RSI vs Cutler RSI on the same candles
Compare recursively smoothed RSI with a finite-window variant and walk through a hand calculation.
-
MACD with three adjustable periods
Change the fast, slow and signal EMA periods and inspect the effect on the MACD lines and histogram.
-
ATR across daily and four-hour candles
Compare the same ATR period across BTC/USD daily and four-hour bars and normalize by price.
-
Bollinger Bands with adjustable periods and width
Change the moving average window and deviation multiplier on a BTC/USD chart.
Backtesting
-
One strategy in three Python backtesting engines
Run the same next-open orders and commission model in Backtrader, Backtesting.py and vectorbt.
-
Backtest fills at the close or next open
Use the same signal and see how four units of price gap change a hypothetical trade.
-
Model fees and slippage in a backtest
Reconcile realistic entry and exit prices, percentage commissions and net performance.
-
Walk-forward tests with rolling windows
Train, validate and test in chronological folds while controlling leakage between market periods.
-
Test whether strategy parameters are stable
Use a neighborhood of settings, trading costs and a frozen validation procedure to spot fragile peaks.
-
Detect look-ahead bias in a backtest
Run a truncated-history check and verify when market data, labels and external features become available.
APIs and execution
-
REST vs WebSocket for Bitcoin market data
Read a Kraken BTC/USD snapshot, subscribe to ticker updates and compare delivery semantics.
-
Restore WebSocket subscriptions after a disconnect
Separate socket connection, subscription acknowledgement, state synchronization and readiness.
-
Handle partial fills without double-counting
Track fill IDs, cumulative quantity, average price and cancellation state on the order ledger.
-
Test market and limit orders in a sandbox
Use a known book fixture to verify price constraints, fills and the remaining order quantity.
-
Prevent duplicate orders after request timeouts
Persist an order intent and reconcile ambiguous submissions before sending another request.
-
Trade event time versus receive time
Keep exchange timestamps and local arrival order for analysis and faithful event replay.
Risk and performance
-
Maximum drawdown from an equity curve
Compute a running peak, mark the deepest decline and change the example equity curve.
-
Measure the time to recover from a drawdown
Distinguish peak-to-recovery, trough-to-recovery and an episode still open at the end.
-
How sampling frequency changes the Sharpe ratio
Compare per-period Sharpe, risk-free conversion and the assumptions behind annualization.
-
Profit factor versus win rate
Compare two simulated trade samples and calculate both metrics after execution costs.
-
Rolling correlation of Bitcoin and Ether returns
Adjust the BTC/ETH Pearson window and compare matched daily return observations.
-
How position size changes backtest results
Replay the same synthetic trades with two fixed sizes and compare equity and drawdown.