Reading schematic¶
A hand-drawn two-line text, with fixations snapped to its lines and arced saccades.
- Download the words and fixations, then choose + → Import files in the app.
- Add the two tables as a dataset. Select its only trial and Reset visualization.
- In Fixations → Snap, choose To line and show the reading order. In Saccades → Shape, choose Arc.
- In Figure & canvas, use a 450 × 340 canvas and hide the duration size key. Set the Illustration label text to “Illustration · hand-drawn”.
import scanpath_studio as sps
from scanpath_studio.measures import fixation_in_text_mask
from scanpath_studio.synthetic import load_synthetic_data
words, fixations = load_synthetic_data()
fixations = fixations[fixation_in_text_mask(fixations, words)].copy()
pid, tid = "synthetic", "synthetic_2line_demo"
fig = sps.plot_scanpath(
words,
fixations,
pid,
tid,
highlight_column=None,
canvas_size=(450, 340),
fixation_snap_to_line=True,
saccade_render_mode="Arc",
illustration_text="Illustration · hand-drawn",
show_order=True,
duration_size_legend=False,
)
sps.save_figure(fig, "illustration.html")