Are there any interesting visualization examples in Julia?

I found a web page with a lot of dazzling and interesting javascript visualization examples. It’s true that programming language is the best drawing tool. Since Julia is very fast and easy to use, I assume it can do a lot of visualization work, and even some are difficult to do in other languages. So, are there any interesting visualization examples in Julia about chaos, fractal, CV, NLP, optimization… or anything else?

2 Likes

Welcome to the community @Wind
I think there are some examples created with Plots.jl but I don’t have links for them but some others might. Just saw some on Twitter tagged with #julialang and maybe animation. Another variant is to use Makie.jl for it which supports 3D stuff.

@TheCedarPrince and I wanted to see more of that kind of animations though and created a library for it. It’s definitely not there yet but you mind find it interesting.
The library: GitHub - JuliaAnimators/Javis.jl: Julia Animations and Visualizations

Some animations:

Latest:

8 Likes

I have a package named WordCloud.jl. Word clouds are used to visualize text data, and WordCloud.jl is the most flexible one as far as I can see. It can generate some results that other generators can’t. This is because the non-greedy bin packing algorithm it uses is flexible but very time-consuming. I’ve taken a lot of optimizations (quadtree, parallelism, generations, LRU, and so on) to ensure it runs fast enough. But I can’t imagine how to implement it without a great language that as usable as Python and as fast as C :smirk:.
Here are some examples.
Comparison of Obama’s and Trump’s inaugural address
address_compare2
Animation of Training Process
animation

11 Likes

Plots of Gaussian processes at Home · AbstractGPsMakie.jl.

So, are there any interesting visualization examples in Julia about chaos, fractal, CV, NLP, optimization… or anything else?

For the anything else: https://lazarusa.github.io/BeautifulMakie/

2 Likes

There are other cool examples in that thread.

4 Likes

Thank you. Javis is full of magic!!

1 Like

WordCloud is really an interesting stuff. The text data is clear at a glance. BTW, the comparison GIF is impressive.

I love Alice !!!

Great package you have made.

Which visualization package is this?

1 Like

Neat… What’s the objective function for something like this?

Can we rank the most said words? like how many America word has been said.

Do you mean rank words in a specific document? If my understanding is correct, it can be easily done by something like that

using WordCloud
doc = pkgdir(WordCloud) * "/res/alice.txt"
sort(collect(countwords(open(doc))), by=last, rev=true)

3019-element Vector{Pair{String, Int64}}:
“the” => 1530
“and” => 803
“to” => 725
“it” => 523
“she” => 506
“of” => 503
“said” => 456
“Alice” => 398
“in” => 359

1 Like

It’s not so much like a common optimization problem, which has a continuous and differentiable optimization objective function. For a nesting problem(or packing problem), the objective function can be density (minimize the waste of material). But for word cloud, high density is not the only target. It just try to get a well distributed (evenly scattered) layout on a set density. The uniformity is achieved by initialization. The only constraint of optimization is that words should not overlap each other. So, if there is any overlap, the value of the objective function is infinite, otherwise it is 0.
The package Stuffing.jl provides optimization algorithm for WordCloud.jl. The introduction of the algorithm can be found here.

1 Like

Aha, so something like

   maximize   Base font size
 subject to   Everything fits in the frame
              No words overlap each other

?

Very cool project, I might try copying the algorithm one day as an exercise…

The Base font size is calculated according to the set density in advance and remains unchanged throughout the optimization process.

1 Like

This package of yours can be great, imagine if we can use sensor that read people mind and know what they think mostly everyday, in a week, in a month, in a year. Then gather all people in a planet…

1 Like