API Documentation

Here we list the Application Programming Interface (API) for MNE-BIDS.

MNE BIDS (mne_bids)

write_raw_bids(raw, bids_basename, bids_root)

Save raw data to a BIDS-compliant folder structure.

read_raw_bids(bids_fname, bids_root[, …])

Read BIDS compatible data.

make_bids_folders(subject[, session, kind, …])

Create a BIDS folder hierarchy.

make_bids_basename([subject, session, task, …])

Create a partial/full BIDS filename from its component parts.

make_dataset_description(path, name[, …])

Create json for a dataset description.

write_anat(bids_root, subject, t1w[, …])

Put anatomical MRI data into a BIDS format.

get_head_mri_trans(bids_fname, bids_root)

Produce transformation matrix from MEG and MRI landmark points.

get_matched_empty_room(bids_fname, bids_root)

Get matching empty room file.

get_anonymization_daysback(raws)

Get the group min and max number of daysback necessary for BIDS specs.

Utils (mne_bids.utils)

print_dir_tree(folder[, max_depth])

Recursively print dir tree starting from folder up to max_depth.

get_entity_vals(bids_root, entity_key)

Get list of values associated with an entity_key in a BIDS dataset.

get_kinds(bids_root)

Get list of data types (“kinds”) present in a BIDS dataset.

Copyfiles (mne_bids.copyfiles)

copyfile_brainvision(vhdr_src, vhdr_dest[, …])

Copy a BrainVision file triplet to a new location and repair links.

copyfile_eeglab(src, dest)

Copy a EEGLAB files to a new location and adjust pointer to ‘.fdt’ file.

copyfile_ctf(src, dest)

Copy and rename CTF files to a new location.

copyfile_bti(raw, dest)

Copy BTi data.

copyfile_kit(src, dest, subject_id, …)

Copy and rename KIT files to a new location.

Datasets (mne_bids.datasets)

fetch_faces_data([data_path, repo, subject_ids])

Dataset fetcher for OpenfMRI dataset ds000117.

fetch_brainvision_testing_data([data_path])

Download the MNE-Python testing data for the BrainVision format.