问题
I would like to use latex with the Plotly backend. Look in this example: Even the x-axis and y-axis log scales are not formatted properly! Do you know how to do that?
Best,
v.
using Plots, LaTeXStrings
plotlyjs()
x = 10 .^ LinRange(-5,5,10)
plot(x, 1 ./ x, yaxis=:log, xaxis=:log, m = 2, xlabel="x", label="1/x",ylabel="f(x)")
plot!(x, 10 ./ x, m=2,label="10/x")
plot!(x, 1 ./ (x.^2), m=2, label=L"f(x)=$1/x^2$")
savefig("./test.png")
回答1:
Seems to work with the gr()
backend, so I expect LaTeXString is not supported by the plotlyjs()
backend.
来源:https://stackoverflow.com/questions/64791134/plotly-julia-latex