Skip to main content

Parse and analyse chords

Project description

build status Documentation Status coverage downloads downloads

chordparser is a Python 3 package that provides a musical framework to analyse chords. Chord notation can be parsed into Chords, which can then be analysed against other chords or the key of the song. This allows for harmonic analysis in chord sheets and helps musicians understand why and how chord progressions work.

Quick demo:

>>> import chordparser
>>> cp = chordparser.Parser()

>>> new_chord = cp.create_chord("C7add4/E")
>>> new_chord.notes
(E note, C note, F note, G note, B note)

>>> new_chord.transpose_simple(6)
F7add4/A chord
>>> new_chord.notes
(A note, F note, B note, C note, E note)

>>> e_scale = cp.create_scale("E", "major")
>>> cp.to_roman(new_chord, e_scale)
II65 roman chord

>>> e_fifth = cp.create_diatonic(e_scale, 5)
>>> e_fifth
B chord
>>> cp.analyse_secondary(new_chord, e_fifth, e_scale)


  • Create and manipulate notes, keys, scales and chords easily
  • Parse complex chord notations
  • Transpose musical classes easily and accurately
  • Automatically generate notes for scales and chords from notation
  • Generate roman numeral notation from chords
  • Analyse chord-scale relationships


To install chordparser, run this command in your terminal:

$ pip install chordparser


Check out the Colab notebook, which runs through a working example to showcase chordparser’s functions and help you get started on using it.

The full documentation can be found here.


If you are having issues, please let me know at:


Development Lead


The project is licensed under the MIT license.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for chordparser, version 0.4.1
Filename, size File type Python version Upload date Hashes
Filename, size chordparser-0.4.1-py3-none-any.whl (29.8 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size chordparser-0.4.1.tar.gz (30.7 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page