# 3D array to heatmap

**URL:** <https://discourse.julialang.org/t/3d-array-to-heatmap/8579>\
**Category:** General Usage\
**Created:** [January 24, 2018, 11:44pm UTC](https://discourse.julialang.org/t/3d-array-to-heatmap/8579 "2018-01-24T23:44:49Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Romero\_Azzalini](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/romero_azzalini/32/10325_2.png) [@Romero\_Azzalini](https://discourse.julialang.org/u/Romero_Azzalini)\
**Post date:** [January 24, 2018, 11:44pm UTC](https://discourse.julialang.org/t/3d-array-to-heatmap/8579/1 "2018-01-24T23:44:49Z")

</div>

Hi,  
I’m kind of desperate, I have a 3D array formated like x,y,z and i want to show the z value in a squared heatmap. The columns are sorted like x:aaabbbccc, y:abcabcabc (but not just with 3 values, instead 600). How am I converting the array, that pcolor is doing it like the way I want, with the right x and y values also (not just enumerating them).

Best,  
Hannes

---

<div class="post-metadata">

**Author:** ![IlyaOrson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ilyaorson/32/1681_2.png) [@IlyaOrson](https://discourse.julialang.org/u/IlyaOrson)\
**Post date:** [January 25, 2018, 3:23am UTC](https://discourse.julialang.org/t/3d-array-to-heatmap/8579/2 "2018-01-25T03:23:18Z")

</div>

See the [documentation](http://docs.juliaplots.org/latest/examples/pyplot/#heatmap-categorical-axes-and-aspect_ratio) of `Plots.jl`.

---

<div class="post-metadata">

**Author:** ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)\
**Post date:** [January 25, 2018, 9:39am UTC](https://discourse.julialang.org/t/3d-array-to-heatmap/8579/3 "2018-01-25T09:39:07Z")

</div>

Please don’t double post questions without referencing the other place. [julia - Heatmap out of 3D array - Stack Overflow](https://stackoverflow.com/questions/48434746/heatmap-out-of-3d-array)

---

<div class="post-metadata">

**Author:** ![Romero\_Azzalini](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/romero_azzalini/32/10325_2.png) [@Romero\_Azzalini](https://discourse.julialang.org/u/Romero_Azzalini)\
**Post date:** [January 25, 2018, 8:42pm UTC](https://discourse.julialang.org/t/3d-array-to-heatmap/8579/4 "2018-01-25T20:42:47Z")

</div>

This post was temporarily hidden by the community for possibly being off-topic, unfocused, inappropriate, or spammy.

---

<div class="post-metadata">

**Author:** ![bernhard](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/bernhard/32/2619_2.png) [@bernhard](https://discourse.julialang.org/u/bernhard)\
**Post date:** [January 25, 2018, 9:13pm UTC](https://discourse.julialang.org/t/3d-array-to-heatmap/8579/5 "2018-01-25T21:13:48Z")

</div>

I do not have an answer to your question.  
But I would assume that your chances of getting support are higher if you are more polite than in your last post.  
Maybe you could post what you habe tried. Or show some code/MWE example with sample data (which might actually help you to get a very concrete answer, ie code)

---

<div class="post-metadata">

**Author:** ![Romero\_Azzalini](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/romero_azzalini/32/10325_2.png) [@Romero\_Azzalini](https://discourse.julialang.org/u/Romero_Azzalini)\
**Post date:** [January 25, 2018, 11:27pm UTC](https://discourse.julialang.org/t/3d-array-to-heatmap/8579/6 "2018-01-25T23:27:19Z")

</div>

Hi,  
I already have solved the problem on my own, although it took longer than expected. You are right, eventhough you have to admit that persons posting links to standard documentation are very likely not going to help anybody… In my opinion it’s more demotivating to get such answers instead of getting no answer… In fact, in my opinion it is even offensive.
