Algorithmic Trading from Scratch

Algorithmic Trading Educational Portal

A comprehensive educational guide to the world of systematic trading — from market microstructure, data acquisition, risk engines, and matching mechanics, to optimizing massive time-series storage in Parquet and Polars.

Algo Pipeline Architecture v2.4 Core
[1] Data Ingestion (L1/L2/L3 feeds)
[2] Normalization & Storage (Parquet/Arrow)
[3] Alpha Signal & Feature Engine
[4] Risk Engine & Position Sizing
[5] Execution Engine & Smart Order Routing

Chapter 1: Data Foundations of Systematic Trading

In algorithmic trading, an iron rule applies: "Garbage in, garbage out." The success of any quantitative strategy is fundamentally governed by the depth of understanding market data microstructure, representations, provider latency, and processing architecture.

Part 1.1

Financial Asset Classes

Rigorous analysis of the structural differences between Stocks (Equities), ETFs (creation/redemption mechanisms), Indices (price-weighted vs cap-weighted), Crypto (spot vs perpetual swaps), and Forex & Commodities (contango, backwardation, roll yield).

  • Market sessions, SIP & NBBO consolidation
  • Perpetual funding rates and liquidation engines
  • Interactive asset risk-return comparison profile
Explore Part 1.1
Part 1.2

Data Representation & Charts

Transitioning from simple Line charts to the classic Candlestick OHLCV model and non-time-based Kagi charts (Yin/Yang lines, shoulders, waists), Heikin-Ashi, and Renko. Formal definitions of symbols, shadows, indicators, and volume profiles.

  • Candle anatomy and mathematical pattern logic
  • Kagi reversal threshold construction algorithm
  • Interactive canvas chart with type switcher
Explore Part 1.2
Part 1.3

Market Mechanics & Orders

What Long and Short truly mean under the hood. The physical mechanics of short selling: share borrowing, locate rules, borrow fees, margin calls, and short squeezes. Orderbook structure (L1, L2, L3) and order types: Market, Limit, Stop-Loss, Trailing Stop, OCO, IOC, FOK.

  • Mathematical margin call and liquidation price formulas
  • FIFO vs Pro-Rata matching engine mechanics
  • Live interactive Orderbook & PnL calculator
Explore Part 1.3
Part 1.4

Data Providers & Trading

Deep-dive into the critical differences between Paper (simulated) and Live trading. Why backtests lie: slippage, orderbook queue priority, and latency. Comparison of Yahoo Finance, Alpaca, Massive.com (formerly Polygon.io), IBKR, and Hyperliquid L1.

  • Production Python code for REST & WebSocket feeds
  • Hyperliquid SDK & perpetual futures architecture
  • Interactive execution slippage simulator
Explore Part 1.4
Part 1.5

Data Storage: CSV vs Parquet

Why the CSV format is an algorithmic trading bottleneck. Columnar format Apache Parquet, Snappy and Zstandard compression, Dictionary encoding, and Predicate Pushdown. Modern Python & Polars architecture vs legacy Pandas.

  • Multithreaded Rust engine, SIMD and zero-copy in Polars
  • 10,000,000 tick record empirical benchmark
  • Interactive storage & query speed calculator
Explore Part 1.5
Pedagogical Approach

Academic Rigor & Practical Code

Each section delivers an exhaustive, production-grade deep-dive complete with mathematical formulations, production Python architecture, and hands-on interactive tools for intuitive visual understanding.

Bilingual Platform

Switch between Slovak and English at any time using the language selector in the top-right corner of the navigation bar.

Most of the content is generated using AI, inaccuracies may occur