Simple barometer gauge with a kPa scale, based on the design of the Lee Valley Tools barometer.
import barometer
barometer.write_svg("barometer.svg", p_ref=97.35, p_ind=100.20)
Each needle is optional, so the following code will only draw the indicator needle.
barometer.write_svg("barometer.svg", p_ind=100.20)
There is a live image showing the current and past sea level pressure readings for CYEG at dashboard.madphilosopher.ca.
Tested under Python 2.7.12, 2.7.17, and Python 3.5.2, 3.6.9.
The stylized script font used in the example image is Anaktoria, which will only render properly if you have Anaktoria installed on your system.
Rendered using Inkscape, it looks like this PNG image.
My python code adapts the javascript derhuerst/svg-partial-circle by @derhuerst to compute the arc of the pressure scale. Copyright ©️ 2017, Jannis Redmann.