fixed off by one error and added checking each read base against the
reference.