Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] only one el in BIDS.participants.meta #28

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

WillForan
Copy link

This patch skips any field with too few values when narrowing BIDS.participant to command-line specified labels.

But maybe skipping meta specifically is a safer approach.

The index issues show up on issue #27, replacing BIDS.participants with error

The logical indices contain a true value outside of the array bounds.

likely because the meta field is always(?) an array of length 1. No error if the label is also the first participant in the BIDS structure.

BIDS.participants.meta

  struct with fields:

    participant_id: [1x1 struct]
               age: [1x1 struct]
               sex: [1x1 struct]
             group: [1x1 struct]
             
  
  BIDS.participants.meta.participant_id(1).Description, 
    'Participant identifier'

BIDS.participants.meta.sex(1).Description,
    'self-rated by participant, M for male/F for female (TODO: verify)'             

FWIW, I think these are populated from our participants.json file

jq . BIDS/participants.json 
{
  "participant_id": {
    "Description": "Participant identifier"
  },
  "age": {
    "Description": "Age in years (TODO - verify) as in the initial session, might not be correct for other sessions"
  },
  "sex": {
    "Description": "self-rated by participant, M for male/F for female (TODO: verify)"
  },
  "group": {
    "Description": "(TODO: adjust - by default everyone is in control group)"
  }
}

spm_BIDS_App.m Outdated Show resolved Hide resolved
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.

None yet

2 participants