Similarly to this discussion (Is it common to have a negative-positive dB range in underwater spectrograms?), I used the 'seewave' R package to plot the below spectrograms.

enter image description here

I limited the coloured amplitude to 0,-60 and the rest as transparent (the full range was between 0,-144. I used the following R code to generate each spectrogram:

ggspectro(specs, f = 44100) +
  geom_raster(aes(fill = (amplitude)), interpolate = T) +
  scale_fill_gradientn(name = "Amplitude\n(dB)\n", 
                       limits = c(-60,0), 
                       breaks = c(-60,0), 
                       na.value = "transparent", 
                       colours = spectro.colors(30)) +
  scale_x_continuous(expand = c(0, 0)) +
  scale_y_continuous(expand = c(0, 0)) +

Recordings were collected on land using SM4 (Wildlife Acoustics, Inc.) with the following mic specs:

Sensitivity: -35 ±4 dB (0 dB=1V/pa@1kHz)

Signal to Noise Ratio: 80 dB Typ. at 1kHz (1 Pa, A weighted network)

Max Input Sound Level: 126 dB SPL Typ.

The negative scale on the spectrograms should be relative, but I am interested in quantifying the mean, max, and min dB SPL. I am unsure about the reference for dB (dBref argument in spectro), left it NULL as default, although function documentation suggests 2*10e-5 for a 20 microPa reference (I understand that also depends on the mic's sensitivity). Can I use a specific formula to convert my values to dB SPL?


2 Answers 2


To make the answer simple and hoping that I understand your question correctly, note first that

  • You have given max SPL input level of 126 dB.
  • Your plots are dB relative to max input level.

Consequently simply add 126 dB to your plot levels to get dB SPL values.

Edit: If the plots are reference to peak signal power (as indicated by comment) and not to max input level (i.e. full ADC level) than the difference between the two level must be taken care off.

How to do that in R?, there could be multiple options, but a save option is to multiply the normalized input data by 10^(126/20)

Obviously there is also a long way, using sensitivity, amplifier gains and ADC reference voltage, but the calculation should end up to max SPL input level

  • $\begingroup$ Thanks for the suggestions. I noticed however that the 0 relative dB didn’t always correspond to the 126 dB SPL. Relative 0 corresponded to the loudest sound in my recordings. Calculating the Peak Power in each recording (using Raven Pro), I could then use that as the 0 reference. For example, if my Peak Power was -16, I added 110 (maximum input 126 - 16) to the values in my graphs. That way I could get a standardised quantification of sound across my spectrograms. $\endgroup$
    – Andrea
    Dec 7, 2023 at 11:36
  • $\begingroup$ Well, having different reference values for different data makes live difficult, but I reccon you got your answer. I update my answer accordingly $\endgroup$
    – WMXZ
    Dec 7, 2023 at 15:52

The color dimension on your spectrogram, labelled (as "Amplitude (dB)), should already be a Sound Pressure Level (SPL) at a given frequency interval. I guess what you are looking for is the reference constant to apply to your dB amplitude to make it a SPL with a specific reference or at least with a reference common to all your recordings.

If you just want a common reference to all your recordings

From what I can see in the spectro help, there is no normalization which could affect each recording differently, so you can compare your spectrograms if all of them were made using the same dBref value, provided that your full recording chain was kept the same (distance of the mic to the source, analog and digital gains).

If you want a standard 20 µPa reference for air SPL

In the case of air SPL (for you bird sound case), the standard is the sea-level atmospheric pressure $2 \cdot 10^{-5}$ Pa or Pascal (pressure unit), however, it should always be stated somewhere when reporting your value to avoid any ambiguity, e.g. 10 dB SPL (ref 20 µPa). However, a non-arbitrary dB SLP reference makes sense only if your full acoustic measurement chain is calibrated. This is the case for instance in sound level meters. In general, SPL are not calibrated and then the reference is unknown (i.e. the dB SPL should be labelled as "dB SPL (arbitrary reference)").

You can estimate the constant to add to your signal in order to make it close to a dB SPL (ref 20µPa), however this depends not only on the microphone sensitivity (which rules the Pressure-to-voltage conversion), but also on all the other amplitude gains between your microphone and your displayed signal:

  • the analog amplifier gain, if any (e.g. from the sound interface)
  • the digital gains, if any, from the:
    • sound interface
    • recording software
    • sound processing (e.g. if the spectrogram automatically normalizes the spectrum amplitude by the highest one within the recording, or if it plots something else)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.