I noticed the Overpass Mono and Nimbus Sans fonts I used in the SVG exports from ggplot2 charts I posted yesterday don’t render correctly on machines without the fonts installed, as they are not embedded in the SVG file unlike charts I’ve made with MatplotLib
REVISED 10/22, fixed code
The code I posted earlier in the week ago didn’t work correctly. New code works.
I noticed the Overpass Mono and Nimbus Sans fonts I used in the SVG exports from ggplot2 charts I posted yesterday don’t render correctly on machines without the fonts installed, as they are not embedded in the SVG file unlike charts I’ve made with MatplotLib. It turns out there is a simple solution –just use grDevices::svg as the export device. The earlier code seemed to produce broken SVG files.
ggsave('filename.svg', width=1920, height=1080, units='px', dpi=150, device = grDevices::svg )