childmindresearch / bids2table

Efficiently index large-scale BIDS neuroimaging datasets and derivatives
https://childmindresearch.github.io/bids2table/
MIT License
13 stars 5 forks source link

Column aliases #31

Open nx10 opened 7 months ago

nx10 commented 7 months ago

It would be nice if b2t exported the column string IDs as constants:

"ds__dataset", "ent__sub", "ent__ses", "ent__run", "meta_json"
bids2table.DATASET_DATASET
bids2table.ENTITY_SUBJECT
bids2table.ENTITY_SESSION
bids2table.ENTITY_RUN
bids2table.METADATA_JSON

This way they could also have some docstrings explaining what they contain and maybe column datatype attached.

clane9 commented 4 months ago

@nx10 I think this is a good idea. More generally, we can think more about how to make the BIDSTable more user-friendly than a vanilla pandas dataframe (although I think it's nice that we can always fall back to dataframe interaction when needed). Would you want to work on this?