# GLVisualize.jl for multi-dimensional arrays

**URL:** <https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639>\
**Category:** Machine Learning\
**Created:** [November 29, 2016, 9:43pm UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639 "2016-11-29T21:43:24Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![hpoit](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/hpoit/32/245_2.png) [@hpoit](https://discourse.julialang.org/u/hpoit)\
**Post date:** [November 29, 2016, 9:43pm UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/1 "2016-11-29T21:43:24Z")

</div>

@sdanisch is there a way to visualize `A = ones(3,3,3,3,3)` on GLVisualize.jl with some sort of hack?

---

<div class="post-metadata">

**Author:** ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)\
**Post date:** [November 29, 2016, 10:49pm UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/2 "2016-11-29T22:49:22Z")

</div>

What sort of visualization would make sense for such an object? I can’t really picture one (pun intended). I think that’s the biggest stop-gap here: visualizing anything higher than 3 dimensions (or maybe 4 using an animation) is conceptually difficult.

---

<div class="post-metadata">

**Author:** ![hpoit](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/hpoit/32/245_2.png) [@hpoit](https://discourse.julialang.org/u/hpoit)\
**Post date:** [November 29, 2016, 11:10pm UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/3 "2016-11-29T23:10:57Z")

</div>

Maybe something like [this](https://youtu.be/ypc7Ul9LkxA?t=21m24s)?

---

<div class="post-metadata">

**Author:** ![sdanisch](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sdanisch/32/1406_2.png) [@sdanisch](https://discourse.julialang.org/u/sdanisch)\
**Post date:** [November 29, 2016, 11:14pm UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/4 "2016-11-29T23:14:00Z")

</div>

The question is, what do you _need_ to see? Figuring that out is the hardest part, I suppose.  
The video is a cool start! You can always slice things, and show different projections in different windows, or even show sub spaces in a pop-up or things like that 😉

---

<div class="post-metadata">

**Author:** ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)\
**Post date:** [November 29, 2016, 11:16pm UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/5 "2016-11-29T23:16:13Z")

</div>

These projections could be implemented as a series recipe in Plots.jl, and then every backend would have this capability. We’ve also thrown around the idea of series recipes which will automatically reduce dimensions (like PCA or t-SNE reductions on large data and plot them). Maybe there should be a whole HighDimensionalPlots.jl repo of recipes.

---

<div class="post-metadata">

**Author:** ![hpoit](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/hpoit/32/245_2.png) [@hpoit](https://discourse.julialang.org/u/hpoit)\
**Post date:** [November 29, 2016, 11:39pm UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/6 "2016-11-29T23:39:15Z")

</div>

I don’t need to see more than 3D, but it would be nice if GLVisualize could be altered to display 4D.

Can I visualize a 4D array in 3D on GLVisualize?

Aside from that GLVisualize is a helpful addition, particularly the GUI, which I’m using as a reference.

---

<div class="post-metadata">

**Author:** ![sdanisch](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sdanisch/32/1406_2.png) [@sdanisch](https://discourse.julialang.org/u/sdanisch)\
**Post date:** [November 30, 2016, 10:44am UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/7 "2016-11-30T10:44:05Z")

</div>

No one holds you back of adding a default visualization for a 4D array, which is the equivalent of `recipes` for GLVisualize 😉  
But as @ChrisRackauckas pointed out, there is likely not a clear default way.

---

<div class="post-metadata">

**Author:** ![tbreloff](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tbreloff/32/68_2.png) [@tbreloff](https://discourse.julialang.org/u/tbreloff)\
**Post date:** [November 30, 2016, 11:35am UTC](https://discourse.julialang.org/t/glvisualize-jl-for-multi-dimensional-arrays/639/8 "2016-11-30T11:35:37Z")

</div>

User: I would like to time travel… can you help me?  
Community: Just use recipes!

Seriously… a suite of common recipes for visualizing high dimensional data in 2D or 3D would be really great. You probably don’t even need to know much about Plots/GlVisualize to help out.

Who wants to help make it happen? (PlotRecipes is probably the best home for such a thing, btw)
