Private types and functions
Documentation for WaveformDB.jl's internal interface.
WaveformDB
Header
WaveformDB.Header — Typestruct Headerrecordname::String - A string of characters that identify the record. The record name numberof_segments::Union{Nothing,UInt32}
- If the field is present, it indicates that the record is a multi-segment record containing the specified number of segments, and that the header file contains segment specification lines rather than signal specification lines.
numberofsignals::UInt32 - the number of signals samplingfrequency::Float32 units samples/second/signal counterfrequency::Float32 basecountervalue::Float32 samplespersignal::Union{Nothing,UInt32} basetime::Union{Nothing,Time} basedate::Union{Nothing,Date} parentdir::String signal_specs::Vector{SignalSpecLine}
Example header (100.hea in sample-data directory of repo) ––––-START OF FILE–––––-
unnecessary comment
100 2 360 650000 <–-all records up to signal_specs 100.dat 212 200 11 1024 995 -22131 0 MLII
100.dat 212 200 11 1024 1011 20052 0 V5
69 M 1085 1629 x1
Aldomet, Inderal
––––-END OF FILE––––––-
WaveformDB.signalspecline — Methodsignalspecline(h::Header)a getter method for the signalspecline field in the header
Interface
WaveformDB.read_binary — Functionread_binary(io::IO, header::Header, ::WfdbFormat{<:AbstractStorargeFormat})reads a WaveformDB sample file io - IOBuffer for the file ("eg 100.dat") header - header struct containing the information necessary to decode the file F - the format that the file is in
WaveformDB.write_binary — Functionfunction write_binary(io::IO, header::Header, samples::Vector{Int32}, ::WfdbFormat{<:AbstractStorageFormat})reads a WaveformDB sample file io - IOBuffer to write to header - header struct containing the information necessary to encode the file F - the WaveformDB format to encode the output as
WaveformDB.wsignal — Methodwsignal(header::Header, signal::Vector{Int32})writes a signal file to disk. All of the information required to write the file needs to be specified by the header