Skip to content

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)"
  }
}

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.

2 participants