Skip to content

docs: Clarify custom column keyword arguments in ecephys tutorial#2176

Open
Copilot wants to merge 5 commits intodevfrom
copilot/remove-label-key-in-add-electrode-function
Open

docs: Clarify custom column keyword arguments in ecephys tutorial#2176
Copilot wants to merge 5 commits intodevfrom
copilot/remove-label-key-in-add-electrode-function

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 27, 2026

Fix #2093. Users are confused by label in nwbfile.add_electrode(label=...) thinking it's a built-in parameter, when it's actually a custom column defined earlier via add_electrode_column. The same ambiguity exists for quality in add_unit.

Changes

  • docs/gallery/domain/ecephys.py: Added inline comments to add_electrode and add_unit calls clarifying that custom column values are passed as keyword arguments:
nwbfile.add_electrode(
    group=electrode_group,
    label="shank{}elec{}".format(ishank, ielec),  # custom column data can be added as keyword arguments
    location="brain area",
)
nwbfile.add_unit(spike_times=spike_times, quality="good")  # custom column data can be added as keyword arguments

⚡ Quickly spin up Copilot coding agent tasks from anywhere on your macOS or Windows machine with Raycast.

Copilot AI changed the title [WIP] Remove label key in add_electrode function documentation docs: Clarify custom column keyword arguments in ecephys tutorial Mar 27, 2026
Copilot AI requested a review from rly March 27, 2026 00:50
Copilot finished work on behalf of rly March 27, 2026 00:50
@rly rly marked this pull request as ready for review March 27, 2026 00:58
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 27, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.10%. Comparing base (286de2d) to head (f207cbc).

Additional details and impacted files
@@           Coverage Diff           @@
##              dev    #2176   +/-   ##
=======================================
  Coverage   95.10%   95.10%           
=======================================
  Files          29       29           
  Lines        2943     2943           
  Branches      443      443           
=======================================
  Hits         2799     2799           
  Misses         86       86           
  Partials       58       58           
Flag Coverage Δ
integration 72.85% <ø> (ø)
unit 85.35% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Co-authored-by: Ryan Ly <310197+rly@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Documentation]: Remove label key in add_electrode function

2 participants