Sorry for the inconvenience!

Ass @didlybom correctly points out, the LAPACK dependency came about somewhat 
"recently" in version `v0.4.4` and the `-d:nolapack` compilation flag was then 
added in `v0.5.0` for the reason you encountered. Installing LAPACK on Windows 
can be a bit of a pain. In the Github Actions CI we use `msys2` for Windows to 
install LAPACK:

<https://github.com/Vindaar/ggplotnim/blob/master/.github/workflows/ci.yml#L71>

I should have put that into the README under the Windows notes!

Now why do we end up with the LAPACK dependency in the first place? 
`geom_smooth` requires it. `geom_smooth` computes a Savitzky-Golay filter to 
smooth the input data using a polynomial fit, which is done using a linear 
least squares routine from arraymancer, which depends on LAPACK. I've been 
meaning to (at least optionally) provide an alternative implementation that 
uses pure Nim code for this (@c-blake already has code in his 
<https://github.com/c-blake/fitl> that would be useful).

And the reason this also happens when simply compiling a basic line plot is 
that the different `geom_*` are mapped to a variant object. That means which 
`Geom` is used is effectively decided at runtime, so there is no way to know 
that the LAPACK dependency might not be needed.

If you have further questions, feel free to just ping me on matrix/discord!

Reply via email to