# Scientific formatting of y-axis using CairoMakie.jl

**URL:** <https://discourse.julialang.org/t/scientific-formatting-of-y-axis-using-cairomakie-jl/87463>\
**Category:** General Usage\
**Tags:** makie\
**Created:** [September 19, 2022, 10:57am UTC](https://discourse.julialang.org/t/scientific-formatting-of-y-axis-using-cairomakie-jl/87463 "2022-09-19T10:57:52Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![devanshu](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/devanshu/32/37104_2.png) [@devanshu](https://discourse.julialang.org/u/devanshu)\
**Post date:** [September 19, 2022, 10:57am UTC](https://discourse.julialang.org/t/scientific-formatting-of-y-axis-using-cairomakie-jl/87463/1 "2022-09-19T10:57:52Z")

</div>

Hi, I would like to get the formatting of my y-ticks like this  
 ![Screenshot from 2022-09-19 16-19-23](https://global.discourse-cdn.com/julialang/original/3X/8/d/8d5b4be20ff2b8b52bd4884855f8a6b3a10b3404.png)  
How to get this using `CairoMakie.jl` ?

---

<div class="post-metadata">

**Author:** ![tbeason](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tbeason/32/15898_2.png) [@tbeason](https://discourse.julialang.org/u/tbeason)\
**Post date:** [September 19, 2022, 1:23pm UTC](https://discourse.julialang.org/t/scientific-formatting-of-y-axis-using-cairomakie-jl/87463/2 "2022-09-19T13:23:26Z")

</div>

Maybe this section of the docs can help? [Axis](https://docs.makie.org/v0.17.13/examples/blocks/axis/index.html#predefined_tick_formatters)

There is also something a little further down the page about axis scales

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://discourse.julialang.org/u/jules)\
**Post date:** [September 19, 2022, 2:06pm UTC](https://discourse.julialang.org/t/scientific-formatting-of-y-axis-using-cairomakie-jl/87463/3 "2022-09-19T14:06:37Z")

</div>

I never implemented that because I feared the additional complexity of dealing with the axis title if it’s left aligned and other edge cases. You can do this manually by scaling your data with the desired factor and placing a label in that spot:

```julia
x = rand(100)
y = rand(100) .* 10e10
y_scaled = y ./ 10e10

f, ax, sc = scatter(x, y_scaled)
Label(f[1, 1, Top()], halign = :left, L"\times 10^{10}")
f

```

 ![image](https://global.discourse-cdn.com/julialang/original/3X/2/c/2c892ddb8d7ab52f0b43a63612dd2540c4cc5459.png)

---

<div class="post-metadata">

**Author:** ![devanshu](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/devanshu/32/37104_2.png) [@devanshu](https://discourse.julialang.org/u/devanshu)\
**Post date:** [September 19, 2022, 3:54pm UTC](https://discourse.julialang.org/t/scientific-formatting-of-y-axis-using-cairomakie-jl/87463/4 "2022-09-19T15:54:09Z")

</div>

Thank you!
