Detection and analysis apparatus