scisonify.Sonify
- class scisonify.Sonify(data: ndarray, smap: SoundMap | None = None, envelope: EnvelopeADSR | None = None, fs: int | None = 44100)
Class for performing Data Sonification.
Turns a 1-dimensional array-like data variable into musical notes.
Parameters
- data: array-like, required
1-D data variable to perform data sonification on
- smap: SoundMap, optional
SoundMap for mapping data to musical notes
- envelope: EnvelopeADSR, optional
Envelope to apply to each note
- fs: int, optional
Sampling Frequency
- __init__(data: ndarray, smap: SoundMap | None = None, envelope: EnvelopeADSR | None = None, fs: int | None = 44100)
Methods
__init__(data[, smap, envelope, fs])plot([x, xlabel, title, figsize, marker, ...])Plots each data point in terms of its Musical Note representation
to_audio([wave, note_length])Returns an interactive Audio object for use in Notebooks
Each data point represented as a frequency (hz) computed using the stored SoundMap
to_notes()Each data point represented as a Musical Note computed using the stored SoundMap
to_waveform([wave, note_length])Converts a normalized data variable into a waveform.