Code
import os
import matplotlib.pyplot as plt
import warnings
from jaxcmr.analyses.srac import plot_srac
from jaxcmr.helpers import find_project_root, generate_trial_mask, load_data, save_figure
warnings.filterwarnings("ignore")Measure how often items are recalled in their original study order.
The serial recall accuracy curve (SRAC) reports the proportion of trials on which the item studied at each position is recalled in the matching output position. Unlike the serial position curve (which only tracks whether an item is recalled at all), SRAC requires the item to appear at the correct ordinal position in the recall sequence.
The x-axis shows study position and the y-axis shows the probability of recalling that item at the correct output position. Key patterns:
data_path — path to an HDF5 file containing a RecallDataset.figure_dir — directory for saving figures.figure_str — base filename for the saved figure. Leave empty to display without saving.ylim — y-axis limits as a tuple, or None for automatic scaling.trial_query — a Python expression evaluated against the dataset to select trials.size — maximum number of study positions a single item can occupy.confidence_level — confidence level for subject-wise error bars.