Data Lab node

Signal Spectrogram

A spectrogram of any Signal: at every update the FFT of the last Size samples becomes one row of a time × frequency matrix that keeps History seconds. Plot it as a Heatmap (rows are frequency bins labelled in Hz, the horizontal axis is time). Magnitude in the input’s unit or dB; Max Frequency crops the top.

Inputs

PortTypeDefault
SignalThe Data Lab signal to analyse — a Signal node's output, a Window, or any float array with its sample rate. Multi-channel signals are handled per channel.structure—
ChannelThe channel analysed.int0
SizeFFT length per row in samples (power of two, ≤ 4096).int256
WindowWindow function per row.int0
OutputMagnitude in the input’s unit, or dB.int0
Max FrequencyCrop the rows above this frequency (Hz); 0 = up to half the sample rate.float0
HistoryHow many seconds of rows the matrix keeps.float10
Update RateRows per second: every update adds one row — this is the time resolution of the picture.float20

Outputs

PortType
Spectrogramstructure
Latest Binsfloat
Peak Frequencyfloat

How It Works

Signal Spectrogram builds a time × frequency matrix: at every update it takes the FFT of the last Size samples and writes it as one row, keeping History seconds of rows.

Plot draws the result as a Heatmap — rows are frequency bins labelled in Hz, the horizontal axis is time — and Plot 3D's Surface turns the same matrix into a lit heightfield. Output is magnitude in the input's unit or dB, and Max Frequency crops the top of the range so the interesting part fills the picture.

Use Cases

  • See a sound — The classic audio spectrogram, for any Signal rather than only the audio engine.
  • Watch a sweep — A frequency change over time is obvious here and invisible in a single spectrum.
  • EEG time-frequency — How the bands rise and fall over a minute.
  • Data sculpture — The matrix into Plot 3D's Surface makes a landscape you can orbit.
  • Ridgeline material — A spectrogram is a matrix, and Plot's Ridgeline kind stacks matrices into the pulsar plot.

Tips

  • Size trades time resolution against frequency resolution — the uncertainty is fundamental, so pick which one you need.
  • dB output is almost always the more readable picture; magnitude hides everything below the loudest thing.
  • Max Frequency is the fastest improvement to most spectrograms: crop away the empty top half.
  • History times Update Rate is the number of rows; very long histories at high rates cost memory.
  • Use a perceptual colour ramp (via Plot's Ramp) — a rainbow invents structure that is not in the data.

Open Signal Spectrogram in the interactive catalog →

Signal Spectrogram is one of 381 nodes in Grafit Pro.

Free download. Every feature for 7 days, no card. Then €99.99 once — or keep playing your projects as a Player.

More Data Lab nodes