Change plot window size in Julia notebook

2.1k views Asked by At

I am using Julia notebook and making plots using basic Plots package.

A plot looks good, except its entire size.

Plot without adjusting any size

I can change the plot size and font size of labels individually. But it becomes less readable unless I change the font size and line width for every component.

Plot when I adjust size and xtickfontsize

So is there a way to change the size of a plot as a whole? I also hope I can change it by default.

1

There are 1 answers

0
logankilpatrick On

To answer your original question in the title, you can change the size of the Plot Window by specifying the size attribute as you already are in your code. See here: http://docs.juliaplots.org/latest/basics/ for more details.

As pointed out by Rashid, you can use the scalefontsize function to scale the font size. You can also scale the thickness by setting the thickness_scaling attribute, see here for more details: http://docs.juliaplots.org/latest/generated/attributes_plot/

To be clear, there is not currently a unified way to scale a plot in the way you are looking for it right now, it has to be done manually (though it would be great to have this unified scaling). I opened a feature request for this here: https://github.com/JuliaPlots/Plots.jl/issues/3153