Mathematical and statistical analysis of the Trypanosoma brucei slender to stumpy transition