  A magnetoconductivity formula is presented for the surface states of a
magnetically doped topological insulator. It reveals a competing effect of weak
localization and weak antilocalization in quantum transport when an energy gap
is opened at the Dirac point by magnetic doping. It is found that, while random
magnetic scattering always drives the system from the symplectic to the unitary
class, the gap could induce a crossover from weak antilocalization to weak
localization, tunable by the Fermi energy or the gap. This crossover presents a
unique feature characterizing the surface states of a topological insulator
with the gap opened at the Dirac point in the quantum diffusion regime.
