Neat! Pickled Muskrat!

    @tonaljs/roman-numeral
    TypeScript icon, indicating that this package has built-in type declarations

    4.6.5 • Public • Published

    @tonaljs/roman-numeral tonal npm version

    Functions to parse roman numeral strings (like the ones used for chord analysis)

    A roman numeral symbol is a string like "bVIImaj7" that can be used to represent chords in an abstract tonallity.

    Usage

    ES6:

    import { RomanNumeral } from "@tonaljs/tonal";

    node:

    const { RomanNumeral } = require("@tonaljs/tonal");

    API

    RomanNumeral.get(src: string | Pitch): => RomanNumeral

    Get the properties of a roman numeral:

    Example:

    RomanNumeral.get("bVIIMaj7");
    // =>
    // {
    //   empty: false,
    //   name: "bVIIMaj7",
    //   roman: "VII",
    //   acc: "b",
    //   chordType: "Maj7",
    //   alt: -1,
    //   step: 6,
    //   major: true,
    //   oct: 0
    // }

    FAQ

    How do I get a roman numeral from an interval

    romanNumeral function accepts a Pitch as argument:

    import { Interval, RomanNumeral } from "@tonaljs/tonal";
    
    RomanNumeral.get(Interval.get("3m")).name; // => "bIII"

    Want more?

    Take a look to @tonal/progression or @tonal/key

    Install

    npm i @tonaljs/roman-numeral

    DownloadsWeekly Downloads

    319

    Version

    4.6.5

    License

    MIT

    Unpacked Size

    10.7 kB

    Total Files

    8

    Last publish

    Collaborators

    • danigb