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
I was trying to reproduce the "Images with custom axes" example from the official documentation, when I figured that it creates some strange behaviour using the pyplot backend:
So, just taking the original code yields the same result as give in the documentation. However using the following slightly modified code for use with the pyplot() backend does not create the right axis:
using Plots
using TestImages
pyplot()
img =testimage("lighthouse");
plot([-π, π], [-1, 1], reverse(img, dims =1), yflip =false, aspect_ratio =:none)
plot!(sin, -π, π, lw =3, color =:red)
The result will be a plot which has as a x-axis with the intervall [-2π, 2π] and a y-axis with the intervall [-2,2]. It's completley unclear to me why the pyplot backend doubles the values given in the command.
Altough it is extremley easy to quickfix this problem with the command
I was trying to reproduce the "Images with custom axes" example from the official documentation, when I figured that it creates some strange behaviour using the pyplot backend:
So, just taking the original code yields the same result as give in the documentation. However using the following slightly modified code for use with the pyplot() backend does not create the right axis:
The result will be a plot which has as a x-axis with the intervall [-2π, 2π] and a y-axis with the intervall [-2,2]. It's completley unclear to me why the pyplot backend doubles the values given in the command.
Altough it is extremley easy to quickfix this problem with the command
I don't think that this can be considered a good solution.
The text was updated successfully, but these errors were encountered: