mne-tools / mne-tools/mne-python
Obtaining annotations with plot window still open with fig.mne
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 3.5k
- Forks
- 1.6k
- Avg merge
- 1d 6h
- Merged PRs (30d)
- 100
Description
The following will allow me, within a separate script, to use fig.mne to recover the bad channels with the plot window open and drop them from raw:
fig=raw.plot()
bads=fig.mne.info[‘bads’]
raw.drop_channels(bads)
Can we do the same for annotations? In other words, suppose I wish to access annotations within a script without closing the plot window? Does fig.mne.inst.annotations have this capability, or could it modified to do so?
Was asked to post this request here and tag @drammock
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the object returned by raw.plot() and how fig.mne exposes its underlying instance. Check whether annotations are available through fig.mne.inst.annotations while the plot remains open, and identify the relevant plotting implementation and tests. Done means a script can access the annotations without closing the plot window, with coverage for that behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data-visualization
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100