@abi-software/map-side-bar 2.3.1 → 2.4.0-alpha-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.js +12 -12
- package/.postcssrc.json +5 -5
- package/LICENSE +201 -201
- package/README.md +168 -168
- package/cypress.config.js +23 -23
- package/dist/data/pmr-sample.json +3181 -0
- package/dist/map-side-bar.js +15142 -9024
- package/dist/map-side-bar.umd.cjs +50 -103
- package/dist/style.css +1 -1
- package/package.json +77 -77
- package/public/data/pmr-sample.json +3181 -0
- package/reporter-config.json +9 -9
- package/src/App.vue +266 -265
- package/src/algolia/algolia.js +255 -242
- package/src/algolia/utils.js +100 -100
- package/src/assets/_variables.scss +43 -43
- package/src/assets/styles.scss +6 -6
- package/src/components/BadgesGroup.vue +124 -124
- package/src/components/ConnectivityInfo.vue +619 -619
- package/src/components/DatasetCard.vue +367 -357
- package/src/components/EventBus.js +3 -3
- package/src/components/ExternalResourceCard.vue +113 -113
- package/src/components/FlatmapDatasetCard.vue +171 -0
- package/src/components/ImageGallery.vue +542 -542
- package/src/components/PMRDatasetCard.vue +237 -0
- package/src/components/SearchFilters.vue +1023 -1006
- package/src/components/SearchHistory.vue +175 -175
- package/src/components/SideBar.vue +436 -436
- package/src/components/SidebarContent.vue +730 -603
- package/src/components/Tabs.vue +145 -145
- package/src/components/allPaths.js +5928 -0
- package/src/components/index.js +8 -8
- package/src/components/pmrTest.js +4 -0
- package/src/components/species-map.js +8 -8
- package/src/components.d.ts +2 -0
- package/src/exampleConnectivityInput.js +291 -291
- package/src/flatmapQueries/flatmapQueries.js +169 -0
- package/src/main.js +9 -9
- package/src/mixins/S3Bucket.vue +37 -37
- package/src/mixins/mixedPageCalculation.vue +78 -0
- package/static.json +6 -6
- package/vite.config.js +55 -55
- package/vuese-generator.js +65 -65
package/src/algolia/algolia.js
CHANGED
|
@@ -1,242 +1,255 @@
|
|
|
1
|
-
/* eslint-disable no-alert, no-console */
|
|
2
|
-
import algoliasearch from 'algoliasearch'
|
|
3
|
-
|
|
4
|
-
// export `createAlgoliaClient` to use it in page components
|
|
5
|
-
export class AlgoliaClient {
|
|
6
|
-
constructor(algoliaId, algoliaKey, PENNSIEVE_API_LOCATION = 'https://api.pennsieve.io') {
|
|
7
|
-
this.client = algoliasearch(
|
|
8
|
-
algoliaId,
|
|
9
|
-
algoliaKey
|
|
10
|
-
)
|
|
11
|
-
this.PENNSIEVE_API_LOCATION = PENNSIEVE_API_LOCATION
|
|
12
|
-
this.anatomyFacetLabels = []
|
|
13
|
-
}
|
|
14
|
-
initIndex(ALGOLIA_INDEX) {
|
|
15
|
-
this.index = this.client.initIndex(ALGOLIA_INDEX);
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
getAlgoliaFacets(propPathMapping) {
|
|
19
|
-
const facetPropPaths = propPathMapping.map(facet => facet.facetPropPath)
|
|
20
|
-
const facetSubpropPaths = propPathMapping.map(item => item.facetSubpropPath)
|
|
21
|
-
let facetData = []
|
|
22
|
-
let facetId = 0
|
|
23
|
-
return this.index
|
|
24
|
-
.search('', {
|
|
25
|
-
sortFacetValuesBy: 'alpha',
|
|
26
|
-
facets: facetPropPaths.concat(facetSubpropPaths),
|
|
27
|
-
})
|
|
28
|
-
.then(response => {
|
|
29
|
-
facetPropPaths.map((facetPropPath) => {
|
|
30
|
-
const parentFacet = propPathMapping.find(item => item.facetPropPath == facetPropPath)
|
|
31
|
-
var children = []
|
|
32
|
-
const responseFacets = response.facets
|
|
33
|
-
if (responseFacets === undefined) {return}
|
|
34
|
-
const responseFacetChildren =
|
|
35
|
-
responseFacets[facetPropPath] == undefined // if no facets, return empty object
|
|
36
|
-
? {}
|
|
37
|
-
: responseFacets[facetPropPath]
|
|
38
|
-
const allPossibleChildrenSubfacets = parentFacet && responseFacets[parentFacet.facetSubpropPath] ? Object.keys(responseFacets[parentFacet.facetSubpropPath]) : []
|
|
39
|
-
// Loop through all subfacets and find the ones that are children of the current facet
|
|
40
|
-
Object.keys(responseFacetChildren).map(facet => {
|
|
41
|
-
const childrenSubfacets = allPossibleChildrenSubfacets.reduce((filtered, childFacetInfo) => {
|
|
42
|
-
const info = childFacetInfo.split('.');
|
|
43
|
-
if (info.length !== 2) {
|
|
44
|
-
return filtered;
|
|
45
|
-
}
|
|
46
|
-
if (facet === info[0]) {
|
|
47
|
-
filtered.push({
|
|
48
|
-
label: info[1],
|
|
49
|
-
id: facetId++,
|
|
50
|
-
facetPropPath: `${parentFacet ? parentFacet.facetSubpropPath : undefined}`
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
return filtered;
|
|
54
|
-
}, []); // Provide an empty array as the initial value
|
|
55
|
-
let newChild = {
|
|
56
|
-
label: facet,
|
|
57
|
-
id: facetId++,
|
|
58
|
-
facetPropPath: facetPropPath
|
|
59
|
-
}
|
|
60
|
-
if (childrenSubfacets.length > 0) {
|
|
61
|
-
newChild.children = childrenSubfacets
|
|
62
|
-
}
|
|
63
|
-
children.push(newChild)
|
|
64
|
-
})
|
|
65
|
-
if (children.length > 0) {
|
|
66
|
-
facetData.push({
|
|
67
|
-
label: parentFacet ? parentFacet.label : '',
|
|
68
|
-
id: facetId++,
|
|
69
|
-
children: children,
|
|
70
|
-
key: facetPropPath
|
|
71
|
-
})
|
|
72
|
-
}
|
|
73
|
-
})
|
|
74
|
-
return facetData
|
|
75
|
-
})
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
// Returns all DOIs of all versions for a given discover dataset
|
|
79
|
-
_discoverAllDois(discoverId, PENNSIEVE_API_LOCATION = 'https://api.pennsieve.io') {
|
|
80
|
-
return new Promise(resolve => {
|
|
81
|
-
fetch(`${PENNSIEVE_API_LOCATION}/discover/datasets/${discoverId}/versions`).then(r => r.json()).then(dataset => {
|
|
82
|
-
resolve(dataset.map(version => version.doi))
|
|
83
|
-
})
|
|
84
|
-
})
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
// Get all dois given a list of discoverIds
|
|
88
|
-
_expandDois(discoverIds, PENNSIEVE_API_LOCATION = 'https://api.pennsieve.io') {
|
|
89
|
-
return new Promise(resolve => {
|
|
90
|
-
let promiseList = discoverIds.map(discoverId => this._discoverAllDois(discoverId, PENNSIEVE_API_LOCATION))
|
|
91
|
-
Promise.all(promiseList).then((values) => {
|
|
92
|
-
resolve(values.flat())
|
|
93
|
-
});
|
|
94
|
-
})
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
_processResultsForCards(results) {
|
|
98
|
-
let newResults = []
|
|
99
|
-
let newResult = {}
|
|
100
|
-
for (let res of results) {
|
|
101
|
-
newResult = { ...res }
|
|
102
|
-
newResult = {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
let
|
|
120
|
-
let
|
|
121
|
-
let
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
*
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
'
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
.
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
1
|
+
/* eslint-disable no-alert, no-console */
|
|
2
|
+
import algoliasearch from 'algoliasearch'
|
|
3
|
+
|
|
4
|
+
// export `createAlgoliaClient` to use it in page components
|
|
5
|
+
export class AlgoliaClient {
|
|
6
|
+
constructor(algoliaId, algoliaKey, PENNSIEVE_API_LOCATION = 'https://api.pennsieve.io') {
|
|
7
|
+
this.client = algoliasearch(
|
|
8
|
+
algoliaId,
|
|
9
|
+
algoliaKey
|
|
10
|
+
)
|
|
11
|
+
this.PENNSIEVE_API_LOCATION = PENNSIEVE_API_LOCATION
|
|
12
|
+
this.anatomyFacetLabels = []
|
|
13
|
+
}
|
|
14
|
+
initIndex(ALGOLIA_INDEX) {
|
|
15
|
+
this.index = this.client.initIndex(ALGOLIA_INDEX);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
getAlgoliaFacets(propPathMapping) {
|
|
19
|
+
const facetPropPaths = propPathMapping.map(facet => facet.facetPropPath)
|
|
20
|
+
const facetSubpropPaths = propPathMapping.map(item => item.facetSubpropPath)
|
|
21
|
+
let facetData = []
|
|
22
|
+
let facetId = 0
|
|
23
|
+
return this.index
|
|
24
|
+
.search('', {
|
|
25
|
+
sortFacetValuesBy: 'alpha',
|
|
26
|
+
facets: facetPropPaths.concat(facetSubpropPaths),
|
|
27
|
+
})
|
|
28
|
+
.then(response => {
|
|
29
|
+
facetPropPaths.map((facetPropPath) => {
|
|
30
|
+
const parentFacet = propPathMapping.find(item => item.facetPropPath == facetPropPath)
|
|
31
|
+
var children = []
|
|
32
|
+
const responseFacets = response.facets
|
|
33
|
+
if (responseFacets === undefined) {return}
|
|
34
|
+
const responseFacetChildren =
|
|
35
|
+
responseFacets[facetPropPath] == undefined // if no facets, return empty object
|
|
36
|
+
? {}
|
|
37
|
+
: responseFacets[facetPropPath]
|
|
38
|
+
const allPossibleChildrenSubfacets = parentFacet && responseFacets[parentFacet.facetSubpropPath] ? Object.keys(responseFacets[parentFacet.facetSubpropPath]) : []
|
|
39
|
+
// Loop through all subfacets and find the ones that are children of the current facet
|
|
40
|
+
Object.keys(responseFacetChildren).map(facet => {
|
|
41
|
+
const childrenSubfacets = allPossibleChildrenSubfacets.reduce((filtered, childFacetInfo) => {
|
|
42
|
+
const info = childFacetInfo.split('.');
|
|
43
|
+
if (info.length !== 2) {
|
|
44
|
+
return filtered;
|
|
45
|
+
}
|
|
46
|
+
if (facet === info[0]) {
|
|
47
|
+
filtered.push({
|
|
48
|
+
label: info[1],
|
|
49
|
+
id: facetId++,
|
|
50
|
+
facetPropPath: `${parentFacet ? parentFacet.facetSubpropPath : undefined}`
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
return filtered;
|
|
54
|
+
}, []); // Provide an empty array as the initial value
|
|
55
|
+
let newChild = {
|
|
56
|
+
label: facet,
|
|
57
|
+
id: facetId++,
|
|
58
|
+
facetPropPath: facetPropPath
|
|
59
|
+
}
|
|
60
|
+
if (childrenSubfacets.length > 0) {
|
|
61
|
+
newChild.children = childrenSubfacets
|
|
62
|
+
}
|
|
63
|
+
children.push(newChild)
|
|
64
|
+
})
|
|
65
|
+
if (children.length > 0) {
|
|
66
|
+
facetData.push({
|
|
67
|
+
label: parentFacet ? parentFacet.label : '',
|
|
68
|
+
id: facetId++,
|
|
69
|
+
children: children,
|
|
70
|
+
key: facetPropPath
|
|
71
|
+
})
|
|
72
|
+
}
|
|
73
|
+
})
|
|
74
|
+
return facetData
|
|
75
|
+
})
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
// Returns all DOIs of all versions for a given discover dataset
|
|
79
|
+
_discoverAllDois(discoverId, PENNSIEVE_API_LOCATION = 'https://api.pennsieve.io') {
|
|
80
|
+
return new Promise(resolve => {
|
|
81
|
+
fetch(`${PENNSIEVE_API_LOCATION}/discover/datasets/${discoverId}/versions`).then(r => r.json()).then(dataset => {
|
|
82
|
+
resolve(dataset.map(version => version.doi))
|
|
83
|
+
})
|
|
84
|
+
})
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
// Get all dois given a list of discoverIds
|
|
88
|
+
_expandDois(discoverIds, PENNSIEVE_API_LOCATION = 'https://api.pennsieve.io') {
|
|
89
|
+
return new Promise(resolve => {
|
|
90
|
+
let promiseList = discoverIds.map(discoverId => this._discoverAllDois(discoverId, PENNSIEVE_API_LOCATION))
|
|
91
|
+
Promise.all(promiseList).then((values) => {
|
|
92
|
+
resolve(values.flat())
|
|
93
|
+
});
|
|
94
|
+
})
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
_processResultsForCards(results) {
|
|
98
|
+
let newResults = []
|
|
99
|
+
let newResult = {}
|
|
100
|
+
for (let res of results) {
|
|
101
|
+
newResult = { ...res }
|
|
102
|
+
newResult = {
|
|
103
|
+
dataSource: 'SPARC',
|
|
104
|
+
anatomy: res.anatomy ? res.anatomy.organ.map((organ => organ.curie)) : undefined,
|
|
105
|
+
doi: res.item.curie.split(':')[1],
|
|
106
|
+
name: res.item.name,
|
|
107
|
+
description: res.item.description,
|
|
108
|
+
updated: res.pennsieve ? res.pennsieve.updatedAt : undefined,
|
|
109
|
+
publishDate: res.pennsieve ? res.pennsieve.publishDate : undefined,
|
|
110
|
+
datasetId: res.objectID,
|
|
111
|
+
detailsReady: false
|
|
112
|
+
}
|
|
113
|
+
newResults.push(newResult)
|
|
114
|
+
}
|
|
115
|
+
return newResults
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
_processAnatomy(hits) {
|
|
119
|
+
let foundKeyWords = []
|
|
120
|
+
let foundLabels = []
|
|
121
|
+
let uniqueLabels = []
|
|
122
|
+
let uniqueKeywords = []
|
|
123
|
+
hits.forEach(hit => {
|
|
124
|
+
if (hit.item && hit.item.keywords) {
|
|
125
|
+
hit.item.keywords.forEach(keywordObj => {
|
|
126
|
+
let keyword = keywordObj.keyword.toUpperCase()
|
|
127
|
+
if (keyword.includes('UBERON') || keyword.includes('ILX')) {
|
|
128
|
+
foundKeyWords.push(this._processUberonURL(keyword))
|
|
129
|
+
}
|
|
130
|
+
})
|
|
131
|
+
}
|
|
132
|
+
if (hit.anatomy && hit.anatomy.organ ) {
|
|
133
|
+
hit.anatomy.organ.forEach(anatomy => {
|
|
134
|
+
if (anatomy.curie) {
|
|
135
|
+
foundKeyWords.push(anatomy.curie)
|
|
136
|
+
foundLabels.push(anatomy.name)
|
|
137
|
+
}
|
|
138
|
+
})
|
|
139
|
+
}
|
|
140
|
+
})
|
|
141
|
+
uniqueKeywords = [...new Set(foundKeyWords) ]
|
|
142
|
+
uniqueLabels = [...new Set(foundLabels) ]
|
|
143
|
+
this.anatomyFacetLabels = uniqueLabels
|
|
144
|
+
return uniqueKeywords
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
_processUberonURL(url) {
|
|
148
|
+
let ub = url.split('/').pop()
|
|
149
|
+
return ub.replace('_', ':')
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* Get Search results
|
|
154
|
+
* This is using fetch from the Algolia API
|
|
155
|
+
*/
|
|
156
|
+
search(filter, query = '', offset = 0, length = 8) {
|
|
157
|
+
// If the length is 0, return an empty result
|
|
158
|
+
if (length === 0) {
|
|
159
|
+
return new Promise(resolve => {
|
|
160
|
+
resolve({
|
|
161
|
+
items: [],
|
|
162
|
+
total: 0,
|
|
163
|
+
discoverIds: [],
|
|
164
|
+
dois: []
|
|
165
|
+
})
|
|
166
|
+
})
|
|
167
|
+
} else {
|
|
168
|
+
return new Promise(resolve => {
|
|
169
|
+
this.index
|
|
170
|
+
.search(query, {
|
|
171
|
+
facets: ['*'],
|
|
172
|
+
offset: offset,
|
|
173
|
+
length: length,
|
|
174
|
+
filters: filter,
|
|
175
|
+
attributesToHighlight: [],
|
|
176
|
+
attributesToRetrieve: [
|
|
177
|
+
'pennsieve.publishDate',
|
|
178
|
+
'pennsieve.updatedAt',
|
|
179
|
+
'item.curie',
|
|
180
|
+
'item.name',
|
|
181
|
+
'item.description',
|
|
182
|
+
'objectID',
|
|
183
|
+
'anatomy.organ.curie'
|
|
184
|
+
],
|
|
185
|
+
})
|
|
186
|
+
.then(response => {
|
|
187
|
+
let searchData = {
|
|
188
|
+
items: this._processResultsForCards(response.hits),
|
|
189
|
+
total: response.nbHits,
|
|
190
|
+
discoverIds: response.hits.map(r => r.pennsieve ? r.pennsieve.identifier : r.objectID),
|
|
191
|
+
dois: response.hits.map(r => r.item.curie.split(':')[1])
|
|
192
|
+
}
|
|
193
|
+
resolve(searchData)
|
|
194
|
+
})
|
|
195
|
+
})
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
/**
|
|
200
|
+
* Get key words
|
|
201
|
+
* This is used to return all keywords for a given search. Note that you often want the hits per page to be maxed out
|
|
202
|
+
*/
|
|
203
|
+
anatomyInSearch(filter, query = '', hitsperPage = 999999, page = 1) {
|
|
204
|
+
return new Promise(resolve => {
|
|
205
|
+
this.index
|
|
206
|
+
.search(query, {
|
|
207
|
+
facets: ['*'],
|
|
208
|
+
hitsPerPage: hitsperPage,
|
|
209
|
+
page: page - 1,
|
|
210
|
+
filters: filter,
|
|
211
|
+
attributesToHighlight: [],
|
|
212
|
+
attributesToRetrieve: [
|
|
213
|
+
'objectID',
|
|
214
|
+
'item.keywords.keyword',
|
|
215
|
+
'anatomy.organ.name',
|
|
216
|
+
'anatomy.organ.curie'
|
|
217
|
+
],
|
|
218
|
+
})
|
|
219
|
+
.then(response => {
|
|
220
|
+
// Saving the line below incase we want to starty using keywords again
|
|
221
|
+
// let anatomyAsUberons = this._processAnatomy(response.hits)
|
|
222
|
+
|
|
223
|
+
resolve({
|
|
224
|
+
forFlatmap: this.processResultsForFlatmap(response.hits),
|
|
225
|
+
forScaffold: this.processResultsForScaffold(response.hits)
|
|
226
|
+
})
|
|
227
|
+
})
|
|
228
|
+
})
|
|
229
|
+
}
|
|
230
|
+
processResultsForFlatmap(hits) {
|
|
231
|
+
let curieForDatsets = hits.map(h=>({
|
|
232
|
+
id: h.objectID,
|
|
233
|
+
terms: h.anatomy? h.anatomy.organ.map(o=>o.curie) : []
|
|
234
|
+
}))
|
|
235
|
+
return curieForDatsets
|
|
236
|
+
}
|
|
237
|
+
processResultsForScaffold(hits) {
|
|
238
|
+
let numberOfDatasetsForAnatomy = {}
|
|
239
|
+
hits.forEach(hit => {
|
|
240
|
+
if (hit.anatomy && hit.anatomy.organ ) {
|
|
241
|
+
hit.anatomy.organ.forEach(anatomy => {
|
|
242
|
+
if (anatomy.name) {
|
|
243
|
+
if (numberOfDatasetsForAnatomy[anatomy.name]) {
|
|
244
|
+
numberOfDatasetsForAnatomy[anatomy.name]++
|
|
245
|
+
} else {
|
|
246
|
+
numberOfDatasetsForAnatomy[anatomy.name] = 1
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
})
|
|
250
|
+
}
|
|
251
|
+
})
|
|
252
|
+
return numberOfDatasetsForAnatomy
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
}
|