billboard-parser-1.0.0.1: A parser for the Billboard chord dataset

Portabilitynon-portable
Stabilityexperimental
MaintainerW. Bas de Haas <bash@cs.uu.nl>
Safe HaskellSafe-Inferred

Billboard.BeatBar

Description

Summary: Modelling musical time (in a minimalistic way) with beats, bars and time signatures.

Synopsis

Documentation

newtype TimeSig Source

Model a time signature as a fraction

Constructors

TimeSig 

Fields

timeSig :: (Int, Int)
 

Instances

data BeatWeight Source

Barlines can have different weights. Among other applications, this is used in the printing of chord sequences.

beatWeight :: TimeSig -> Int -> BeatWeightSource

Defines the metrical weight of a bar. A regular beat has strength 0, a bar has strength 1, a bar after 4 bars 2, a bar after 8 bars 3, and a bar after 16 bars 4.

tatumsPerBar :: TimeSig -> IntSource

Returns the number of tatums in a bar which is different for time signatures. For example:

>>> tatumsPerBar (TimeSig (3 ,4))
6
>>> tatumsPerBar (TimeSig (6 ,8))
6
>>> tatumsPerBar (TimeSig (12,8))
12

N.B. This function is not strictly correct music-theoretically, but it reflects how Billboard annotators used time signatures.

chordsPerDot :: TimeSig -> IntSource

Returns the number of BBChord that are inserted for one ., based on a TimeSignature.