ThunderFish
Algorithms and programs for analysing electric field recordings of weakly electric fish.
Weakly electric fish generate an electric organ discharge (EOD). In wave-type fish the EOD resembles a sinewave of a specific frequency and with higher harmonics. In pulse-type fish EODs have a distinct waveform and are separated in time. The thunderfish package provides algorithms and tools for analysing both wavefish and pulsefish EODs.
Installation
ThunderFish is available from PyPi. Simply run:
pip install thunderfish
If you have problems loading specific audio files with thunderfish, then you need to install further packages. Follow the installation instructions of the AudioIO package.
Software
The thunderfish package provides the following software:
fishfinder
: Browse EOD recordings and detect EOD frequencyies on the fly.thunderfish
: Detect, analyze, and plot all EOD waveforms in short recordings.collectfish
: Collect data generated bythunderfish
.eodexplorer
: View and explore properties of EOD waveforms.thunderbrowse
: Browse multi-channel EOD recordings.thunderlogger
: Extract EOD waveforms from logger recordings.convertdata
: Convert data from various file formats to audio files.
Algorithms
The following modules provide the algorithms for analyzing EOD recordings. Look into the modules for more information.
Input/output
configfile
: Configuration file with help texts for analysis parameter.consoleinput
: User input from console.dataloader
: Load time-series data from files.datawriter
: Write time-series data to files.tabledata
: Read and write tables with a rich hierarchical header including units and formats.
Basic data analysis
eventdetection
: Detect and hande peaks and troughs as well as threshold crossings in data arrays.powerspectrum
: Compute and plot powerspectra and spectrograms for a given minimum frequency resolution.voronoi
: Analyse Voronoi diagrams based on scipy.spatial.multivariateexplorer
: Simple GUI for viewing and exploring multivariate data.
EOD analysis
bestwindow
: Select the region within a recording with the most stable signal of largest amplitude that is not clipped.checkpulse
: Check whether a pulse-type or a wave-type weakly electric fish is present in a recording.consistentfishes
: Create a list of EOD frequencies with fishes present in all provided fish lists.eodanalysis
: Analyse EOD waveforms.harmonics
: Extract and analyze harmonic frequencies from power spectra.pulses
: Extract and cluster EOD waverforms of pulse-type electric fish.
EOD simulations
fakefish
: Simulate EOD waveforms.efield
: Simulations of spatial electric fields.fishshapes
: Manipulate and plot fish outlines.