# Thickness\_scaling in Plots.jl

**URL:** <https://discourse.julialang.org/t/thickness-scaling-in-plots-jl/12539>\
**Category:** Visualization\
**Created:** [July 20, 2018, 2:41pm UTC](https://discourse.julialang.org/t/thickness-scaling-in-plots-jl/12539 "2018-07-20T14:41:25Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jcrbloch](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jcrbloch/32/4396_2.png) [@jcrbloch](https://discourse.julialang.org/u/jcrbloch)\
**Post date:** [July 20, 2018, 2:41pm UTC](https://discourse.julialang.org/t/thickness-scaling-in-plots-jl/12539/1 "2018-07-20T14:41:25Z")

</div>

I used thickness\_scaling = 0.5 in plot() when using Plots but instead of making all lines narrower it enlarges the plot by a factor two.

---

<div class="post-metadata">

**Author:** ![daschw](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/daschw/32/2926_2.png) [@daschw](https://discourse.julialang.org/u/daschw)\
**Post date:** [July 25, 2018, 1:59pm UTC](https://discourse.julialang.org/t/thickness-scaling-in-plots-jl/12539/2 "2018-07-25T13:59:31Z")

</div>

I cannot reproduce. Which backend are you using? Which version of Plots are you on?

Here’s the current behaviour for GR:

```julia
using Plots
gr(size = (300, 300), linewidth = 2)
plot(sin, -π, π)

```

![gr_def](https://global.discourse-cdn.com/julialang/original/3X/c/f/cf30f87844028562f50eb791b79bc2a03d0f956c.png)

```julia
plot(sin, -π, π, thickness_scaling = 0.5)

```

![gr_ts](https://global.discourse-cdn.com/julialang/original/3X/5/6/5603c7a939debc939c76f3d24cf4482d4de5533f.png)

```julia
plot(sin, -π, π, dpi = 200)

```

 ![gr_dpi](https://global.discourse-cdn.com/julialang/original/3X/7/1/7161be4558c2ae1c898df8a88365ab8e39ecfaaa.png)

Is this not expected?

---

<div class="post-metadata">

**Author:** ![jcrbloch](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/jcrbloch/32/4396_2.png) [@jcrbloch](https://discourse.julialang.org/u/jcrbloch)\
**Post date:** [July 25, 2018, 2:12pm UTC](https://discourse.julialang.org/t/thickness-scaling-in-plots-jl/12539/3 "2018-07-25T14:12:02Z")

</div>

I am using the pyplot backend on julia 0.6.4, with Plots 0.17.3 and PyPlot 2.6.0. I did not expect what you show. Between the first and the second plot I don’t see a decrease in line thickness of the axes for example, nor of the legend box. However, the fonts are decreased by a lot, which is not expected.

---

<div class="post-metadata">

**Author:** ![daschw](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/daschw/32/2926_2.png) [@daschw](https://discourse.julialang.org/u/daschw)\
**Post date:** [July 25, 2018, 2:35pm UTC](https://discourse.julialang.org/t/thickness-scaling-in-plots-jl/12539/4 "2018-07-25T14:35:02Z")

</div>

The font size and the line widths are increased or decreased by the same factor. Maybe that’s better visible with these examples:

```julia
plot(sin, -π, π, thickness_scaling = 1)

```

![gr_ts1](https://global.discourse-cdn.com/julialang/original/3X/4/2/42c31ee391ff42f210d0e3c82841d4a774bb8832.png)

```julia
plot(sin, -π, π, thickness_scaling = 5)

```

![gr_ts5](https://global.discourse-cdn.com/julialang/original/3X/1/2/12acbb358ba15014054f9f670d05e91ba1470248.png)

I just checked `pyplot()` and I can confirm the problem you described above. It would be great if you could open an issue on Plots.jl for this. Thanks!

---

<div class="post-metadata">

**Author:** ![daschw](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/daschw/32/2926_2.png) [@daschw](https://discourse.julialang.org/u/daschw)\
**Post date:** [July 25, 2018, 9:51pm UTC](https://discourse.julialang.org/t/thickness-scaling-in-plots-jl/12539/5 "2018-07-25T21:51:30Z")

</div>

Nvm, should be fixed by [fix pyplot thickness\_scaling (fix #1606) by daschw · Pull Request #1610 · JuliaPlots/Plots.jl · GitHub](https://github.com/JuliaPlots/Plots.jl/pull/1610)  
Thanks for reporting!
