Heatmap with mousepicking no axis markings and labels

I output a heatmap, points and lines, to a scene in order to allow mouse interactions similar to this example.


However contrary to the example documentation no axis markings and labels appear. What to do, to get them?

My version of the sample:

import Pkg; Pkg.add("GLMakie"); using GLMakie

img = rand(100, 100)
scene = Scene(resolution = (500, 500))
# , scale_plot = false
heatmap!(scene, img)
clicks = Node(Point2f0[(0,0)])
#on(scene.events.mousebuttons) do buttons
on(scene.events.mousebutton) do buttons
     if ispressed(scene, Mouse.left)
          pos = to_world(scene,  Point2f0(scene.events.mouseposition[]))
         clicks[] = push!(clicks[], pos)
scatter!(scene, clicks, color = :red, marker = '+', markersize = 10)
# Do not execute beyond this point!
RecordEvents(scene, "output")

That juliaplots.org site is very old, nowadays Scene doesn’t usually carry around its own axis anymore. Have a look at the actual documentation here: Observables & Interaction · Makie

Great thanks Jules,

my present version of the sample:

import Pkg; Pkg.add(“GLMakie”); using GLMakie

img = rand(1000, 1000)
fig, ax = heatmap(img)

Makie.deactivate_interaction!(ax, :rectanglezoom)
spoint = select_point(ax.scene, marker = :circle)
clicks = Observable(Point2f)

on(spoint) do spoint
push!(clicks, spoint)
scatter!(ax, clicks, color = :gray, strokecolor = :red, strokewidth = 10)
lines!(ax, clicks, color = :red, strokecolor = :red, linewidth = 5)