Skip to content

Is it possible to collect metadata and datasets from dandi using matlab? #57

Answered by bendichter
ehennestad asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for the question, @ehennestad

DANDI uses a REST API, which can be accessed using many different languages, including MATLAB. You can find documentation detailing the available commands here and here. I have drafted a tutorial with an example workflow below:

%% Get all dandisets
dandisets = webread('https://api.dandiarchive.org/api/dandisets/?page_size=1000').results

%% Get identifers for NWB dandisets

nwb_identifier = 'RRID:SCR_015242';

nwb_dandiset_identifiers = {};

for i = 1:length({dandisets.identifier})
    identifier = dandisets(i).identifier;
    version_url = ['https://api.dandiarchive.org/api/dandisets/' identifier '/versions/draft'];
    assetsSummary = webread(version…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by ehennestad
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants