A method of examining a sample using a spectroscopic apparatus, comprising the following steps: - Mounting the sample on a sample holder; - Directing a focused input beam of radiation onto a location on the sample, thereby producing an interaction that causes a flux of stimulated photonic radiation to emanate from said location; - Examining said flux using a multi-channel photon-counting detector, thus accruing a measured spectrum for said location; - Automatically repeating said directing and examining steps for a series of successive locations on the sample, said method comprising the following steps: - Choosing a beam parameter of the input beam that will influence a magnitude of said flux of stimulated photonic radiation; - Selecting a first value of said beam parameter; - In a first measurement run, maintaining said first value of the beam parameter whilst acquiring a spectrum for each location in a first set of locations on the sample; - Selecting a second value of said beam parameter; - In a second measurement run, maintaining said second value of the beam parameter whilst acquiring a spectrum for each location in a second set of locations on the sample, the method being further characterized by the following steps: - During said first measurement run, generating an event signal if the detector encounters two successive photons that are separated by a temporal interval below a given acceptance value; - Generating a flag signal if, at a given location L f, the number of generated event signals exceeds a particular threshold, and storing the location L f in a memory; - In response to generation of a flag signal, choosing said second value of the beam parameter so as to reduce the magnitude of said flux of stimulated photonic radiation; - Choosing the second set of locations to include at least a subset of the locations L f. - Mounting the sample on a sample holder; - Directing a focused input beam of radiation onto a location on the sample, thereby producing an interaction that causes a flux of stimulated photonic radiation to emanate from said location; - Examining said flux using a multi-channel photon-counting detector, thus accruing a measured spectrum for said location; - Automatically repeating said directing and examining steps for a series of successive locations on the sample, said method comprising the following steps: - Choosing a beam parameter of the input beam that will influence a magnitude of said flux of stimulated photonic radiation; - Selecting a first value of said beam parameter; - In a first measurement run, maintaining said first value of the beam parameter whilst acquiring a spectrum for each location in a first set of locations on the sample; - Selecting a second value of said beam parameter; - In a second measurement run, maintaining said second value of the beam parameter whilst acquiring a spectrum for each location in a second set of locations on the sample, the method being further characterized by the following steps: - During said first measurement run, generating an event signal if the detector encounters two successive photons that are separated by a temporal interval below a given acceptance value; - Generating a flag signal if, at a given location L f, the number of generated event signals exceeds a particular threshold, and storing the location L f in a memory; - In response to generation of a flag signal, choosing said second value of the beam parameter so as to reduce the magnitude of said flux of stimulated photonic radiation; - Choosing the second set of locations to include at least a subset of the locations L f.