Binary choice tasks, such as 2-alternative forced choice, show a complex yet consistent pattern of sequential effects, whereby responses and response times depend on the detailed pattern of prior stimuli going back at least 5 trials. We show this pattern is well explained by simultaneous incremental learning of 2 simple statistics of the trial sequence: the base rate and the repetition rate. Both statistics are learned by the same basic associative mechanism, but they contribute different patterns of sequential effects because they entail different representations of the trial sequence. Subtler aspects of the data that are not explained by these 2 learning processes alone are explained by their interaction, via learning from joint error correction. Specifically, the cue-competition mechanism that has explained classic findings in animal learning (e.g., blocking) appears to operate on learning of sequence statistics. We also find that learning of the base rate and repetition rate are dissociated into response and stimulus processing, respectively, as indicated by event-related potentials, manipulations of stimulus discriminability, and reanalysis of past experiments that eliminated stimuli or prior responses. Thus, sequential effects in these tasks appear to be driven by learning the response base rate and the stimulus repetition rate. Connections are discussed between these findings and previous research attempting to separate stimulus- and response-based sequential effects, and research using sequential effects to determine mental representations. We conclude that sequential effects offer a powerful means for uncovering representations and learning mechanisms.