EthanR: made atoi work