You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I’m at the Julia REPL producing plots with PlotlyLight, I can download the plots successfully with this package, and all is well.
However, I’m really interested in producing PDF reports using Quarto. Printing the html report from the browser works, but is not ideal as I would like to automate the process from the command line (using quarto render —to pdf), and produce a PDF version of several Markdown reports. Unfortunately, when using Quarto, images downloaded by PlotlyKaleido are nowhere to be found (at least by me), even if I export them to a hard-coded absolute path. Has anyone successfully used this kind of workflow?
Thanks!
The text was updated successfully, but these errors were encountered:
If it's helpful, here's an example Quarto report. The issue is that I've no idea where myplot.svg is, if anywhere.
---
title: PlotlyLight and Quarto
engine: julia
---
# Environment setup
```{julia}
#| output: false
using Pkg
Pkg.activate("plotlylight-quarto")
Pkg.add("PlotlyLight")
Pkg.add("PlotlyKaleido")
using PlotlyLight
using PlotlyKaleido
PlotlyKaleido.start()
```
# A plot with PlotlyLight
```{julia}
p = plot(x = 1:200, y = cumsum(randn(200)), type="scatter", mode="lines" )
p.layout.title.text = "Your stocks"
display(p) # this plot appears in the html rendering
```
<!-- Now I would like this plot to appear in the pdf rendering -->
```julia
PlotlyKaleido.savefig(p, "myplot.svg")
```
![](myplot.svg)
Render with quarto render report.qmd --execute --to pdf.
Thank you for this package!
When I’m at the Julia REPL producing plots with PlotlyLight, I can download the plots successfully with this package, and all is well.
However, I’m really interested in producing PDF reports using Quarto. Printing the html report from the browser works, but is not ideal as I would like to automate the process from the command line (using
quarto render —to pdf
), and produce a PDF version of several Markdown reports. Unfortunately, when using Quarto, images downloaded by PlotlyKaleido are nowhere to be found (at least by me), even if I export them to a hard-coded absolute path. Has anyone successfully used this kind of workflow?Thanks!
The text was updated successfully, but these errors were encountered: