Revision

Algorithm catalogue & comparisons

Every algorithm from Chapters 2–9 in one place: what it estimates, its update target, whether it needs a model, bootstraps, or learns off-policy — and how it differs from its neighbours.

The catalogue

Filter by property (filters combine). Click a name to jump to its chapter section.

AlgorithmChEstimatesUpdate target / ruleModelBoot-strapsPolicyKey hyper­parameters

The dimensions that classify methods

DimensionOptionsWhat it means
Prediction vs controlestimate $v_\pi$/$q_\pi$ · find $\pi_*$Control is GPI: prediction + improvement.
Modelfull distribution (DP) · sample model (MC simulation) · noneDP needs $p(s',r|s,a)$; MC/TD learn from experience.
Update widthexpected (all successors) · sample (one successor)Expected updates need a model; sample updates add variance.
Update depth1 step (TD) · n steps · whole episode (MC)Bootstrapping depth: bias ↔ variance trade-off.
On- vs off-policylearn about the behaviour policy · about a different target policyOff-policy needs coverage, and IS or max/expectation targets.
Representationtabular · linear · nonlinearFunction approximation generalises; changes convergence guarantees.

Head-to-head comparisons

DP vs MC vs TD

DPMonte CarloTD
Target$\E_\pi[R+\gamma V(S')]$ (model)$G_t$$R+\gamma V(S')$ (sample)
Needs modelyesnono
Bootstrapsyesnoyes
Bias / variance of targetno sampling noiseunbiased, high variancebiased, low variance
Online, continuing tasks—no (episodic, end of episode)yes
Batch solution—min. training MSEcertainty equivalence (ML model)
Non-Markov robustnesslowhigherlower

Policy iteration vs value iteration

Policy iterationValue iteration
Sweep updateBellman expectation (evaluate π fully)Bellman optimality (max) — one sweep of evaluation + improvement
IterationsFew, finite (strict improvement)Many cheap sweeps; converges in the limit
Policy during runexplicitimplicit; extract at end

Sarsa vs Q-learning vs Expected Sarsa vs Double Q-learning

SarsaQ-learningExpected SarsaDouble Q
Target$R+\gamma Q(S',A')$$R+\gamma\max_aQ(S',a)$$R+\gamma\sum_a\pi(a|S')Q(S',a)$$R+\gamma Q_2(S',\argmax_aQ_1(S',a))$
Policyonoffon or offoff
Learns$q$ of ε-greedy π$q_*$$q_\pi$ (greedy π ⇒ $q_*$)$q_*$
Cliff walkingsafe path, better online rewardoptimal edge path, falls offlike Sarsa, better; α = 1 ok—
Variance from $A'$yesnonono
Maximization biassome (ε-greedy max)yessomeremoved
Costlowlowsum over actions2× memory

First-visit vs every-visit MC · ordinary vs weighted IS

First-visitEvery-visit
Usesfirst visit per episodeall visits
Biasunbiasedbiased (→ 0)
Best fortheoryFA, eligibility traces
Ordinary ISWeighted IS
Estimate$\sum\rho G/|\mathcal T|$$\sum\rho G/\sum\rho$
Biasunbiasedbiased (→ 0)
Variancecan be infinitebounded

Exploration mechanisms

MechanismWhereHowDrawback
ε-greedy / ε-softCh 2, 5, 6random action with prob. εindiscriminate; caps performance
Optimistic initial valuesCh 2disappointment drives trying everythingtemporary; stationary only
UCBCh 2uncertainty bonus $c\sqrt{\ln t/N}$hard beyond bandits
Soft-max (gradient bandit)Ch 2sample from $\pi\propto e^H$α-sensitive; needs baseline
Exploring startsCh 5random start (s, a)unrealistic in real interaction
Off-policy behaviour policyCh 5–7explore with b, learn greedy πvariance (IS) / slow tails

Multi-step off-policy options (Ch 7)

ApproachMechanismProCon
n-step with ISmultiply update by $\rho$simple, soundhigh variance
Control variatesper-decision ρ + $(1-\rho)V$ termsame expectation, less variancemore complex
Tree backupweight branches by π; no ρno IS at allshort effective span if π ≠ b
Q(σ)mix sampling (σ=1) and expectation (σ=0)unifies allchoose σ

Gradient MC vs semi-gradient TD vs LSTD (Ch 9)

Gradient MCSemi-gradient TD(0)LSTD
True gradient?yesno (ignores target's dependence on w)closed form
Linear convergenceglobal optimum of VETD fixed point; $\overline{\mathrm{VE}}\le\frac{1}{1-\gamma}\min$TD fixed point directly
Cost per step$O(d)$$O(d)$$O(d^2)$
Speed / data efficiencyslow (variance)fastmost data-efficient
Step sizeααnone (ε regulariser), never forgets

Which algorithm when?

SituationReasonable choiceWhy
Full, accurate model; small state spacePolicy / value iterationExact, polynomial-time
Model but huge state spaceAsynchronous DP on visited statesNo full sweeps
No model, episodic, need values of a few statesMonte CarloIndependent of other states, no bootstrapping
Simulator easy but distributions hard (blackjack)MC (ES or ε-soft)Only needs sample episodes
Continuing task or very long episodesTD (Sarsa / Q-learning / Expected Sarsa)Online, step-by-step
Exploration is costly (online performance matters)Sarsa / Expected SarsaAccounts for its own exploration
Want the optimal greedy policy while exploringQ-learning (Double Q if noisy rewards)Off-policy max target
Learning from another agent's / logged dataOff-policy MC with weighted IS, tree backupSeparate behaviour and target
Sparse delayed reward, slow credit propagationn-step methods (intermediate n)Propagates credit n steps per update
Large/continuous stateSemi-gradient TD with tile coding or Fourier features; LSTD if d smallGeneralisation with linear guarantees