# 'flow' layout in Makie

**URL:** https://discourse.julialang.org/t/flow-layout-in-makie/135646
**Category:** New to Julia
**Tags:** makie, cairomakie
**Created:** [February 14, 2026, 8:07pm UTC](https://discourse.julialang.org/t/flow-layout-in-makie/135646 "2026-02-14T20:07:01Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![mahmah](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mahmah/32/214326_2.png) [@mahmah](https://discourse.julialang.org/u/mahmah)
#### Post date: [February 14, 2026, 8:07pm UTC](https://discourse.julialang.org/t/flow-layout-in-makie/135646/1 "2026-02-14T20:07:01Z")

</div>

Is there any way to easily plot a grid of subfigures in Makie, similarly to e.g. `'layout = 4'` in Plots.jl or do we need to do e.g. `axs = [Axis(fig[i, j]) for i in 1:3, j in 1:3]`  
?

---

<div class="post-metadata">

### Author: ![aplavin](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/aplavin/32/222056_2.png) [@aplavin](https://discourse.julialang.org/u/aplavin)
#### Post date: [February 14, 2026, 8:57pm UTC](https://discourse.julialang.org/t/flow-layout-in-makie/135646/2 "2026-02-14T20:57:26Z")

</div>

I don’t think there’s anything builtin…  
I played with a small helper recently – usage:

```julia-auto
datasets = [data1, data2, ...]
map(datasets, AutoGridLayout(nrows=3)) do data, pos
    image(pos, data)
end

```

implementation:

```julia-auto
AutoGridLayout(fig; ncols=nothing, nrows=nothing) =
    if !isnothing(ncols)
        (fig.layout[I] for I in CartesianIndices((1:10^3, 1:ncols)) |> permutedims)
    elseif !isnothing(nrows)
        (fig.layout[I] for I in CartesianIndices((1:nrows, 1:10^3)))
    end

```

First impression – convenient in the simplest cases 🙂
