Our great sponsors
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
pgfplots
pgfplots - A TeX package to draw normal and/or logarithmic plots directly in TeX in two and three dimensions with a user-friendly interface and pgfplotstable - a TeX package to round and format numerical tables. Examples in manuals and/or on web site.
You'd never get this out of that combination, though, without major rewrites.
Looking through the source code. It looks like it's using tiny-skia for rendering.
But, if you really hate yourself and the self-flagellation doesn’t suit your fancy, you can find a primer on the basics of programming in LaTeX here: https://pgfplots.sourceforge.net/ (look for the technical papers) I did the solving part the most basic, brute force way possible—it was already obnoxious enough. Modern computers are fast enough for even the LaTeX to come up with a solution in a reasonable time frame (still, think minutes, not seconds). I’m sure somebody who actually cares about such things will be able to point you towards something much more sane, but that unfortunately won’t be me.
This sounds like the superior solution. Of course you can run any command inside LaTeX and thus embed code... It just has to output valid LaTeX I think. There's also this: https://github.com/tndrle/PyLuaTeX (to run Python code).