  We numerically study the effects of two forms of quenched disorder on the
anyons of the toric code. Firstly, a new class of codes based on random
lattices of stabilizer operators is presented, and shown to be superior to the
standard square lattice toric code for certain forms of biased noise. It is
further argued that these codes are close to optimal, in that they tightly
reach the upper bound of error thresholds beyond which no correctable CSS codes
can exist. Additionally, we study the classical motion of anyons in toric codes
with randomly distributed onsite potentials. In the presence of repulsive
long-range interaction between the anyons, a surprising increase with disorder
strength of the lifetime of encoded states is reported and explained by an
entirely incoherent mechanism. Finally, the coherent transport of the anyons in
the presence of both forms of disorder is investigated, and a significant
suppression of the anyon motion is found.
