Word-box heatmap¶
Fixation time within each word’s bounding box.
- Select the bundled demo in Scanpath, then participant
l37_1129and triall37_1129_2_1_1_Ele_r0. Start with Reset visualization, turn off Stimulus → Highlight → Show. - Turn on Heatmap. In Heatmap ▾, choose Word boxes and weight by fixation duration.
- Turn off Fixations and Saccades; keep Stimulus on.
import scanpath_studio as sps
words, fixations = sps.load_sample_data()
pid, tid = "l37_1129", "l37_1129_2_1_1_Ele_r0"
fig = sps.plot_scanpath(
words,
fixations,
pid,
tid,
highlight_column=None,
show_heatmap=True,
heatmap_style="Word boxes",
show_fixations=False,
show_saccades=False,
)
sps.save_figure(fig, "word-boxes.html")