# Yaxis scale

**URL:** <https://discourse.julialang.org/t/yaxis-scale/69960>\
**Category:** New to Julia\
**Tags:** plotting, dataframes, statsplots\
**Created:** [October 18, 2021, 7:11am UTC](https://discourse.julialang.org/t/yaxis-scale/69960 "2021-10-18T07:11:20Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![dbjulia](https://avatars.discourse-cdn.com/v4/letter/d/db5fbb/32.png) [@dbjulia](https://discourse.julialang.org/u/dbjulia)\
**Post date:** [October 18, 2021, 7:11am UTC](https://discourse.julialang.org/t/yaxis-scale/69960/1 "2021-10-18T07:11:20Z")

</div>

I am trying to plot some data were the y axis of the plot would be in thousands instead of a log scale. I cannot figure out way to do this in Julia. I have tried a few different back ends but to no avail. Code and image of plot below. This plot is using the gr back end.

julia\> @df summ\_two bar(:Category,cols(2),tickfont = 3 ,legend=false, rotation = 30, tick\_direction = :out, yticks = -100000:1000:100000)

 ![plot](https://global.discourse-cdn.com/julialang/original/3X/2/d/2d8b0430c7acebf5af67c1f2d083c2ba54f7945b.png)

---

<div class="post-metadata">

**Author:** ![gustaphe](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gustaphe/32/18174_2.png) [@gustaphe](https://discourse.julialang.org/u/gustaphe)\
**Post date:** [October 18, 2021, 8:02am UTC](https://discourse.julialang.org/t/yaxis-scale/69960/2 "2021-10-18T08:02:03Z")

</div>

What’s the issue with the picture?

Edit: I think I get it. What you’re seeing is not a logarithmic axis, but scientific notation. You can change it with the `yformatter` attribute (if you’re using `Plots.jl`). It takes either a function `f(x::Number)::String` or one of `:scientific`, `:plain` and `:auto`. I’m guessing `:plain` is what you want.

---

<div class="post-metadata">

**Author:** ![nilshg](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nilshg/32/2283_2.png) [@nilshg](https://discourse.julialang.org/u/nilshg)\
**Post date:** [October 18, 2021, 9:22am UTC](https://discourse.julialang.org/t/yaxis-scale/69960/3 "2021-10-18T09:22:44Z")

</div>

`yformatter = x->x/1000`

---

<div class="post-metadata">

**Author:** ![gustaphe](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gustaphe/32/18174_2.png) [@gustaphe](https://discourse.julialang.org/u/gustaphe)\
**Post date:** [October 18, 2021, 9:35am UTC](https://discourse.julialang.org/t/yaxis-scale/69960/4 "2021-10-18T09:35:33Z")

</div>

Or `yformatter=x->"$(x/1000) k"`.

If they want to just plot the data `/1000`, I would probably do that on the data side.

---

<div class="post-metadata">

**Author:** ![dbjulia](https://avatars.discourse-cdn.com/v4/letter/d/db5fbb/32.png) [@dbjulia](https://discourse.julialang.org/u/dbjulia)\
**Post date:** [October 18, 2021, 5:36pm UTC](https://discourse.julialang.org/t/yaxis-scale/69960/5 "2021-10-18T17:36:26Z")

</div>

Thanks @gustaphe that was what I needed.
