Skip to content

pop_newset: parity with EEGLAB #938

Backlog
Backlog

Description

@arnodelorme

🤖 The dataset storage prompt opens for a modified epoched recording. The native reference window is 247 px high. Qt opens at 365 px and omits conditional controls for storing the previous dataset. This function is part of #875.

Live MATLAB and initial Qt capture

Reproduction

Native MATLAB R2025b and Qt on jamming, using the same input. The guarded capture records EEGLAB 5e0be870 and EEGPrep c94c592. Review the final geometry and submitted values before closing this function issue.

Activity

  1. added
    function-parity
    on Dec 1, 2026
  2. claude commented on Dec 1, 2026

    @claude
    Contributor

    🤖 Plan:

    Research

    The Qt dialog comes from a static DialogSpec that never reads the state of the previous dataset. CURRENTSET is passed to pop_newset_dialog_spec but never used. The spec always shows the "old dataset (not modified since last saved)" text and the overwrite checkbox, and never offers the saveold choice. The window size is also hardcoded at 638x332, plus custom margins and spacing, where EEGLAB derives the height from supergui geometry (247 px).

    Relevant code

    Proposed Fix

    Not implemented here, for three reasons. (1) #875 says the individual window issues are on hold until the shared supergui geometry rework lands. The height mismatch (365 vs 247 px) is the kind of problem that rework should fix at its root, not per window. (2) The vendored src/eegprep/eeglab/ checkout is empty in this environment and network access is blocked, so I could not read pop_newset.m at 5e0be870 to port the conditional uilist exactly. (3) Closing the issue needs a native MATLAB versus Qt capture on jamming, which is not available here.

    Proposed approach once #875 lands:

    1. Make pop_newset_dialog_spec branch on the previous dataset state (ALLEEG(CURRENTSET).saved, filename present, STUDY), mirroring the uilist/geometry branches in pop_newset.m. That means adding the old-dataset "Save it as file" checkbox, edit, and Browse row (saveold) when the old dataset was modified.
    2. Map those controls to saveold in _run_gui.
    3. Drop the hardcoded size, content_margins and row_spacing so supergui sizes the window. Update the pop_newset_dialog parity case to use a modified epoched dataset.
    4. Add a test in tests/test_pop_newset.py asserting the conditional controls appear for a modified previous dataset and that saveold is submitted. Then recapture on jamming.
  3. arnodelorme commented on Dec 1, 2026

    @arnodelorme
    CollaboratorAuthor

    🤖 #1016 targets #974.

    Part of #938 and #875. Show the correct storage options for saved and modified datasets. Stacked on #974.

    Live MATLAB, EEGPrep before and after

    Previous dataset has unsaved changes

    Function output distances

    Vertical control offsets

    Native measurements and validation

    With a saved previous dataset the native windows both measure 247 px high. With unsaved changes both measure 273 px, showing an extra filename row that can actually save the previous recording. The largest vertical displacement across both cases was 0.49 px. A native edit, rename and store returned identical samples and metadata when creating a new dataset and when replacing the current dataset. All 10 focused tests passed, including a test writing and reading the requested previous-dataset file. The measured cases used the ordinary in-memory dataset workflow.

  4. arnodelorme commented on Dec 1, 2026

    @arnodelorme
    CollaboratorAuthor

    Done: Show the correct storage options for saved and modified datasets.

    Pull request: #1016

    — eegprep, reported with orch done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    function-parity

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions