This is a utility module for converting from and to Roman numerals. It supports numbers upto 3,999,999, using the vinculum to denote multiplication by 1000. (i.e.: X is 10 while X̅ is 10000.) The only letter that this does not apply to is I, as M already existed for 1000.
Special credit goes to Paul M. Winkler, for the original basis for a large chunk of the core converter functions as written in the Python Cookbook.
Quick Start
Install the package:
pip3 install romanicize
Once installed, a command line utility is available to your shell:
$ romanicize 2021 MMXXI $ romanicize MMXIX 2019
With a Python script, convert from an integer to a Roman numeral:
from romanicize import to_numeral print(to_numeral(2021)) # Outputs: MMXXI
Within a Python script, convert from a Roman numeral to an integer:
from romanicize import to_int
print(to_int('MV̅DLXXVIII')) # Outputs: 4578
Metadata
Release files for romanicize 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| romanicize-0.1.2.tar.gz | 5.2 kB | Without provenance | Details |
Release files / romanicize-0.1.2.tar.gz
| Download URL | romanicize-0.1.2.tar.gz |
|---|---|
| Size | 5.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0f7db36d27a9fcbf8f492801e6fbbf74f73c6ee9238ff91fc78fd6e055984021
|
|
BLAKE2b-256 checksum How to use checksums |
179fc2c793ca1184973036fe3324dd88f3119d5bfbb5829dafb7367b6e3327bb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.6
|
Security for romanicize 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.