Commit 2227ce4
committed
enh: allow access to PyBIDS' magic
This patch allows users to access the automated querying of the layout
with the ``get_*`` magic (and ``ls_*``, for TF), e.g.:
```Python
>>> from templateflow import api
>>> api.ls_atlases(template="MNI152NLin6Asym")
['DiFuMo', 'Schaefer2018', 'HOCPA', 'HCP', 'HOCPAL', 'HOSPA']
```
The existing ``get_*`` methods are not overshadowed:
```Python
>>> api.get_citations(template="MNI152NLin6Asym")
['https://doi.org/10.1016/j.neuroimage.2012.01.024',
'https://fsl.fmrib.ox.ac.uk/fsl/fslwiki/Atlases']
```
The original ``get_*`` queries are accepted:
```Python
>>> api.get_atlases()
['AAL',
'DiFuMo',
'v3',
'CerebrA',
'D99',
'WHS',
'VALiDATe',
'v4',
'Schaefer2018',
'HOCPA',
'HCP',
'CerebA',
'CCFv3',
'CHARM',
'HOCPAL',
'SARM',
'HOSPA']
```get_*
1 parent 3c1f2cb commit 2227ce4
2 files changed
Lines changed: 23 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
| 3 | + | |
2 | 4 | | |
3 | 5 | | |
4 | | - | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| |||
249 | 250 | | |
250 | 251 | | |
251 | 252 | | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
252 | 263 | | |
253 | 264 | | |
254 | 265 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
0 commit comments