In Plots.jl, how does one control the space between ylabel and yaxis?


#1

I don’t seem to find any example or documentation about this.


#2

I am answering my own question. I found that the option “left_margin = 8mm” works.


#3

https://juliaplots.github.io/attributes/ and (in a julia session with Plots loaded) plotattr(:Subplot) (or :Plot, :Axis, :Series) are your friends.


#4

Thank you for this link - very helpful! :slight_smile:


#5

Thank you.


#6

@mkborregaard is there a page in the docs with tricks like this? They are extremely useful!

In the other post, you gave us the means to explore colorschemes of all kinds, now I learned how to find attributes in the Julia prompt, that is amazing! This should be at the top of the docs somewhere.


#7

E.g. the very top shiny blue box on this page :slight_smile: https://juliaplots.github.io/attributes/

But agreed, some things in the docs (e.g. also the description of legends) could be improved. We often try to solicit PRs to the docs, as the readers of those are really the experts.


#8

I found out that it is not working any more. I got the error message “mm not defined”. None of other units (px, in, etc) seems to work either. I am using Plots.jl v0.13.1 and RecipesBase 0.2.3. Does anyone know if the syntax has changed?


#9

It has, as we had too many namespace clashes. using Plots.PlotMeasures will resurrect the functionality.


#10

Thank you. That’s what I needed to know.


#11

Another question. Is there a way to control the spacing between tick values and the axis?