pyxetabase 4.0.0.dev56__py3-none-any.whl

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.

Potentially problematic release.


This version of pyxetabase might be problematic. Click here for more details.

Files changed (36) hide show
  1. pyxetabase/__init__.py +0 -0
  2. pyxetabase/commons.py +347 -0
  3. pyxetabase/exceptions.py +8 -0
  4. pyxetabase/opencga_client.py +344 -0
  5. pyxetabase/opencga_config.py +211 -0
  6. pyxetabase/rest_clients/__init__.py +0 -0
  7. pyxetabase/rest_clients/_parent_rest_clients.py +144 -0
  8. pyxetabase/rest_clients/admin_client.py +179 -0
  9. pyxetabase/rest_clients/alignment_client.py +373 -0
  10. pyxetabase/rest_clients/clinical_analysis_client.py +1216 -0
  11. pyxetabase/rest_clients/cohort_client.py +349 -0
  12. pyxetabase/rest_clients/cvdb_client.py +2285 -0
  13. pyxetabase/rest_clients/disease_panel_client.py +345 -0
  14. pyxetabase/rest_clients/family_client.py +355 -0
  15. pyxetabase/rest_clients/federation_client.py +133 -0
  16. pyxetabase/rest_clients/file_client.py +710 -0
  17. pyxetabase/rest_clients/ga4gh_client.py +86 -0
  18. pyxetabase/rest_clients/individual_client.py +435 -0
  19. pyxetabase/rest_clients/job_client.py +416 -0
  20. pyxetabase/rest_clients/meta_client.py +85 -0
  21. pyxetabase/rest_clients/organization_client.py +216 -0
  22. pyxetabase/rest_clients/project_client.py +128 -0
  23. pyxetabase/rest_clients/sample_client.py +446 -0
  24. pyxetabase/rest_clients/study_client.py +462 -0
  25. pyxetabase/rest_clients/user_client.py +212 -0
  26. pyxetabase/rest_clients/user_tool_client.py +471 -0
  27. pyxetabase/rest_clients/variant_client.py +1378 -0
  28. pyxetabase/rest_clients/variant_operation_client.py +718 -0
  29. pyxetabase/rest_clients/workflow_client.py +263 -0
  30. pyxetabase/rest_response.py +220 -0
  31. pyxetabase/retry.py +57 -0
  32. pyxetabase-4.0.0.dev56.dist-info/METADATA +159 -0
  33. pyxetabase-4.0.0.dev56.dist-info/RECORD +36 -0
  34. pyxetabase-4.0.0.dev56.dist-info/WHEEL +5 -0
  35. pyxetabase-4.0.0.dev56.dist-info/licenses/LICENSE +202 -0
  36. pyxetabase-4.0.0.dev56.dist-info/top_level.txt +1 -0
@@ -0,0 +1,1216 @@
1
+ """
2
+ WARNING: AUTOGENERATED CODE
3
+
4
+ This code was generated by a tool.
5
+
6
+ Manual changes to this file may cause unexpected behavior in your application.
7
+ Manual changes to this file will be overwritten if the code is regenerated.
8
+ """
9
+
10
+ from pyxetabase.rest_clients._parent_rest_clients import _ParentRestClient
11
+
12
+
13
+ class ClinicalAnalysis(_ParentRestClient):
14
+ """
15
+ This class contains methods for the 'Analysis - Clinical' webservices
16
+ PATH: /{apiVersion}/analysis/clinical
17
+ """
18
+
19
+ def __init__(self, configuration, token=None, login_handler=None, *args, **kwargs):
20
+ super(ClinicalAnalysis, self).__init__(configuration, token, login_handler, *args, **kwargs)
21
+
22
+ def update_acl(self, members, action, data=None, **options):
23
+ """
24
+ Update the set of permissions granted for the member.
25
+ PATH: /{apiVersion}/analysis/clinical/acl/{members}/update
26
+
27
+ :param dict data: JSON containing the parameters to add ACLs.
28
+ (REQUIRED)
29
+ :param str action: Action to be performed [ADD, SET, REMOVE or RESET].
30
+ Allowed values: ['SET ADD REMOVE RESET'] (REQUIRED)
31
+ :param str members: Comma separated list of user or group IDs.
32
+ (REQUIRED)
33
+ :param str study: Study [[organization@]project:]study where study and
34
+ project can be either the ID or UUID.
35
+ :param bool propagate: Propagate permissions to related families,
36
+ individuals, samples and files.
37
+ """
38
+
39
+ options['action'] = action
40
+ return self._post(category='analysis', resource='update', subcategory='clinical/acl', second_query_id=members, data=data, **options)
41
+
42
+ def aggregation_stats(self, **options):
43
+ """
44
+ Fetch catalog clinical analysis aggregation stats.
45
+ PATH: /{apiVersion}/analysis/clinical/aggregationStats
46
+
47
+ :param str study: Study [[organization@]project:]study where study and
48
+ project can be either the ID or UUID.
49
+ :param str id: Comma separated list of Clinical Analysis IDs up to a
50
+ maximum of 100. Also admits basic regular expressions using the
51
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
52
+ sensitive, '~/value/i' for case insensitive search.
53
+ :param str uuid: Comma separated list of Clinical Analysis UUIDs up to
54
+ a maximum of 100.
55
+ :param str type: Clinical Analysis type.
56
+ :param str disorder: Clinical Analysis disorder. Also admits basic
57
+ regular expressions using the operator '~', i.e. '~{perl-regex}'
58
+ e.g. '~value' for case sensitive, '~/value/i' for case insensitive
59
+ search.
60
+ :param str files: Clinical Analysis files.
61
+ :param str sample: Sample associated to the proband or any member of a
62
+ family.
63
+ :param str individual: Proband or any member of a family.
64
+ :param str proband: Clinical Analysis proband.
65
+ :param str proband_samples: Clinical Analysis proband samples.
66
+ :param str family: Clinical Analysis family.
67
+ :param str family_members: Clinical Analysis family members.
68
+ :param str family_member_samples: Clinical Analysis family members
69
+ samples.
70
+ :param str panels: Clinical Analysis panels.
71
+ :param bool locked: Locked Clinical Analyses.
72
+ :param str analyst_id: Clinical Analysis analyst id.
73
+ :param str priority: Clinical Analysis priority.
74
+ :param str flags: Clinical Analysis flags.
75
+ :param str creation_date: Clinical Analysis Creation date. Format:
76
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
77
+ :param str modification_date: Clinical Analysis Modification date.
78
+ Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
79
+ :param str due_date: Clinical Analysis due date. Format:
80
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
81
+ :param str quality_control_summary: Clinical Analysis quality control
82
+ summary.
83
+ :param str release: Release when it was created.
84
+ :param int snapshot: Snapshot value (Latest version of the entry in
85
+ the specified release).
86
+ :param str status: Filter by status.
87
+ :param str internal_status: Filter by internal status.
88
+ :param str annotation: Annotation filters. Example:
89
+ age>30;gender=FEMALE. For more information, please visit
90
+ http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0.
91
+ :param bool deleted: Boolean to retrieve deleted entries.
92
+ :param str field: Field to apply aggregation statistics to (or a list
93
+ of fields separated by semicolons), e.g.:
94
+ studies;type;numSamples[0..10]:1;format:sum(size).
95
+ """
96
+
97
+ return self._get(category='analysis', resource='aggregationStats', subcategory='clinical', **options)
98
+
99
+ def load_annotation_sets(self, variable_set_id, path, data=None, **options):
100
+ """
101
+ Load annotation sets from a TSV file.
102
+ PATH: /{apiVersion}/analysis/clinical/annotationSets/load
103
+
104
+ :param str path: Path where the TSV file is located in OpenCGA or
105
+ where it should be located. (REQUIRED)
106
+ :param str variable_set_id: Variable set ID or name. (REQUIRED)
107
+ :param str study: Study [[organization@]project:]study where study and
108
+ project can be either the ID or UUID.
109
+ :param bool parents: Flag indicating whether to create parent
110
+ directories if they don't exist (only when TSV file was not
111
+ previously associated).
112
+ :param str annotation_set_id: Annotation set id. If not provided,
113
+ variableSetId will be used.
114
+ :param dict data: JSON containing the 'content' of the TSV file if
115
+ this has not yet been registered into OpenCGA.
116
+ """
117
+
118
+ options['variableSetId'] = variable_set_id
119
+ options['path'] = path
120
+ return self._post(category='analysis', resource='load', subcategory='clinical/annotationSets', data=data, **options)
121
+
122
+ def update_clinical_configuration(self, data=None, **options):
123
+ """
124
+ Update Clinical Analysis configuration.
125
+ PATH: /{apiVersion}/analysis/clinical/clinical/configuration/update
126
+
127
+ :param str study: Study [[organization@]project:]study where study and
128
+ project can be either the ID or UUID.
129
+ :param dict data: Configuration params to update.
130
+ """
131
+
132
+ return self._post(category='analysis', resource='update', subcategory='clinical/clinical/configuration', data=data, **options)
133
+
134
+ def create(self, data=None, **options):
135
+ """
136
+ Create a new clinical analysis.
137
+ PATH: /{apiVersion}/analysis/clinical/create
138
+
139
+ :param dict data: JSON containing clinical analysis information.
140
+ (REQUIRED)
141
+ :param str include: Fields included in the response, whole JSON path
142
+ must be provided.
143
+ :param str exclude: Fields excluded in the response, whole JSON path
144
+ must be provided.
145
+ :param str study: Study [[organization@]project:]study where study and
146
+ project can be either the ID or UUID.
147
+ :param bool skip_create_default_interpretation: Flag to skip creating
148
+ and initialise an empty default primary interpretation (Id will be
149
+ '{clinicalAnalysisId}.1'). This flag is only considered if no
150
+ Interpretation object is passed.
151
+ :param bool include_result: Flag indicating to include the created or
152
+ updated document result in the response.
153
+ """
154
+
155
+ return self._post(category='analysis', resource='create', subcategory='clinical', data=data, **options)
156
+
157
+ def distinct(self, field, **options):
158
+ """
159
+ Clinical Analysis distinct method.
160
+ PATH: /{apiVersion}/analysis/clinical/distinct
161
+
162
+ :param str field: Comma separated list of fields for which to obtain
163
+ the distinct values. (REQUIRED)
164
+ :param str study: Study [[organization@]project:]study where study and
165
+ project can be either the ID or UUID.
166
+ :param str id: Comma separated list of Clinical Analysis IDs up to a
167
+ maximum of 100. Also admits basic regular expressions using the
168
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
169
+ sensitive, '~/value/i' for case insensitive search.
170
+ :param str uuid: Comma separated list of Clinical Analysis UUIDs up to
171
+ a maximum of 100.
172
+ :param str type: Clinical Analysis type.
173
+ :param str disorder: Clinical Analysis disorder. Also admits basic
174
+ regular expressions using the operator '~', i.e. '~{perl-regex}'
175
+ e.g. '~value' for case sensitive, '~/value/i' for case insensitive
176
+ search.
177
+ :param str files: Clinical Analysis files.
178
+ :param str sample: Sample associated to the proband or any member of a
179
+ family.
180
+ :param str individual: Proband or any member of a family.
181
+ :param str proband: Clinical Analysis proband.
182
+ :param str proband_samples: Clinical Analysis proband samples.
183
+ :param str family: Clinical Analysis family.
184
+ :param str family_members: Clinical Analysis family members.
185
+ :param str family_member_samples: Clinical Analysis family members
186
+ samples.
187
+ :param str panels: Clinical Analysis panels.
188
+ :param bool locked: Locked Clinical Analyses.
189
+ :param str analyst_id: Clinical Analysis analyst id.
190
+ :param str priority: Clinical Analysis priority.
191
+ :param str flags: Clinical Analysis flags.
192
+ :param str creation_date: Clinical Analysis Creation date. Format:
193
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
194
+ :param str modification_date: Clinical Analysis Modification date.
195
+ Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
196
+ :param str due_date: Clinical Analysis due date. Format:
197
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
198
+ :param str quality_control_summary: Clinical Analysis quality control
199
+ summary.
200
+ :param str release: Release when it was created.
201
+ :param int snapshot: Snapshot value (Latest version of the entry in
202
+ the specified release).
203
+ :param str status: Filter by status.
204
+ :param str internal_status: Filter by internal status.
205
+ :param str annotation: Annotation filters. Example:
206
+ age>30;gender=FEMALE. For more information, please visit
207
+ http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0.
208
+ :param bool deleted: Boolean to retrieve deleted entries.
209
+ """
210
+
211
+ options['field'] = field
212
+ return self._get(category='analysis', resource='distinct', subcategory='clinical', **options)
213
+
214
+ def aggregation_stats_interpretation(self, **options):
215
+ """
216
+ Fetch catalog interpretation aggregation stats.
217
+ PATH: /{apiVersion}/analysis/clinical/interpretation/aggregationStats
218
+
219
+ :param str study: Study [[organization@]project:]study where study and
220
+ project can be either the ID or UUID.
221
+ :param str id: Comma separated list of Interpretation IDs up to a
222
+ maximum of 100. Also admits basic regular expressions using the
223
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
224
+ sensitive, '~/value/i' for case insensitive search.
225
+ :param str uuid: Comma separated list of Interpretation UUIDs up to a
226
+ maximum of 100.
227
+ :param str name: Comma separated list of Interpretation names up to a
228
+ maximum of 100.
229
+ :param str clinical_analysis_id: Clinical Analysis id.
230
+ :param str analyst_id: Analyst ID.
231
+ :param str method_name: Interpretation method name. Also admits basic
232
+ regular expressions using the operator '~', i.e. '~{perl-regex}'
233
+ e.g. '~value' for case sensitive, '~/value/i' for case insensitive
234
+ search.
235
+ :param str panels: Interpretation panels.
236
+ :param str primary_findings: Interpretation primary findings.
237
+ :param str secondary_findings: Interpretation secondary findings.
238
+ :param str creation_date: Interpretation Creation date. Format:
239
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
240
+ :param str modification_date: Interpretation Modification date.
241
+ Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
242
+ :param str status: Filter by status.
243
+ :param str internal_status: Filter by internal status.
244
+ :param str release: Release when it was created.
245
+ :param str field: Field to apply aggregation statistics to (or a list
246
+ of fields separated by semicolons), e.g.:
247
+ studies;type;numSamples[0..10]:1;format:sum(size).
248
+ """
249
+
250
+ return self._get(category='analysis', resource='aggregationStats', subcategory='clinical/interpretation', **options)
251
+
252
+ def distinct_interpretation(self, field, **options):
253
+ """
254
+ Interpretation distinct method.
255
+ PATH: /{apiVersion}/analysis/clinical/interpretation/distinct
256
+
257
+ :param str field: Comma separated list of fields for which to obtain
258
+ the distinct values. (REQUIRED)
259
+ :param str study: Study [[organization@]project:]study where study and
260
+ project can be either the ID or UUID.
261
+ :param str id: Comma separated list of Interpretation IDs up to a
262
+ maximum of 100. Also admits basic regular expressions using the
263
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
264
+ sensitive, '~/value/i' for case insensitive search.
265
+ :param str uuid: Comma separated list of Interpretation UUIDs up to a
266
+ maximum of 100.
267
+ :param str name: Comma separated list of Interpretation names up to a
268
+ maximum of 100.
269
+ :param str clinical_analysis_id: Clinical Analysis id.
270
+ :param str analyst_id: Analyst ID.
271
+ :param str method_name: Interpretation method name. Also admits basic
272
+ regular expressions using the operator '~', i.e. '~{perl-regex}'
273
+ e.g. '~value' for case sensitive, '~/value/i' for case insensitive
274
+ search.
275
+ :param str panels: Interpretation panels.
276
+ :param str primary_findings: Interpretation primary findings.
277
+ :param str secondary_findings: Interpretation secondary findings.
278
+ :param str creation_date: Interpretation Creation date. Format:
279
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
280
+ :param str modification_date: Interpretation Modification date.
281
+ Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
282
+ :param str status: Filter by status.
283
+ :param str internal_status: Filter by internal status.
284
+ :param str release: Release when it was created.
285
+ """
286
+
287
+ options['field'] = field
288
+ return self._get(category='analysis', resource='distinct', subcategory='clinical/interpretation', **options)
289
+
290
+ def search_interpretation(self, **options):
291
+ """
292
+ Search clinical interpretations.
293
+ PATH: /{apiVersion}/analysis/clinical/interpretation/search
294
+
295
+ :param str include: Fields included in the response, whole JSON path
296
+ must be provided.
297
+ :param str exclude: Fields excluded in the response, whole JSON path
298
+ must be provided.
299
+ :param int limit: Number of results to be returned.
300
+ :param int skip: Number of results to skip.
301
+ :param bool sort: Sort the results.
302
+ :param str study: Study [[organization@]project:]study where study and
303
+ project can be either the ID or UUID.
304
+ :param str id: Comma separated list of Interpretation IDs up to a
305
+ maximum of 100. Also admits basic regular expressions using the
306
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
307
+ sensitive, '~/value/i' for case insensitive search.
308
+ :param str uuid: Comma separated list of Interpretation UUIDs up to a
309
+ maximum of 100.
310
+ :param str name: Comma separated list of Interpretation names up to a
311
+ maximum of 100.
312
+ :param str clinical_analysis_id: Clinical Analysis id.
313
+ :param str analyst_id: Analyst ID.
314
+ :param str method_name: Interpretation method name. Also admits basic
315
+ regular expressions using the operator '~', i.e. '~{perl-regex}'
316
+ e.g. '~value' for case sensitive, '~/value/i' for case insensitive
317
+ search.
318
+ :param str panels: Interpretation panels.
319
+ :param str primary_findings: Interpretation primary findings.
320
+ :param str secondary_findings: Interpretation secondary findings.
321
+ :param str creation_date: Interpretation Creation date. Format:
322
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
323
+ :param str modification_date: Interpretation Modification date.
324
+ Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
325
+ :param str status: Filter by status.
326
+ :param str internal_status: Filter by internal status.
327
+ :param str release: Release when it was created.
328
+ """
329
+
330
+ return self._get(category='analysis', resource='search', subcategory='clinical/interpretation', **options)
331
+
332
+ def info_interpretation(self, interpretations, **options):
333
+ """
334
+ Clinical interpretation information.
335
+ PATH: /{apiVersion}/analysis/clinical/interpretation/{interpretations}/info
336
+
337
+ :param str interpretations: Comma separated list of clinical
338
+ interpretation IDs up to a maximum of 100. (REQUIRED)
339
+ :param str include: Fields included in the response, whole JSON path
340
+ must be provided.
341
+ :param str exclude: Fields excluded in the response, whole JSON path
342
+ must be provided.
343
+ :param str study: Study [[organization@]project:]study where study and
344
+ project can be either the ID or UUID.
345
+ :param str version: Comma separated list of interpretation versions.
346
+ 'all' to get all the interpretation versions. Not supported if
347
+ multiple interpretation ids are provided.
348
+ :param bool deleted: Boolean to retrieve deleted entries.
349
+ """
350
+
351
+ return self._get(category='analysis', resource='info', subcategory='clinical/interpretation', second_query_id=interpretations, **options)
352
+
353
+ def run_interpreter_exomiser(self, data=None, **options):
354
+ """
355
+ Run exomiser interpretation analysis.
356
+ PATH: /{apiVersion}/analysis/clinical/interpreter/exomiser/run
357
+
358
+ :param dict data: Exomiser interpretation analysis params. (REQUIRED)
359
+ :param str study: Study [[organization@]project:]study where study and
360
+ project can be either the ID or UUID.
361
+ :param str job_id: Job ID. It must be a unique string within the
362
+ study. An ID will be autogenerated automatically if not provided.
363
+ :param str job_description: Job description.
364
+ :param str job_depends_on: Comma separated list of existing job IDs
365
+ the job will depend on.
366
+ :param str job_tags: Job tags.
367
+ :param str job_scheduled_start_time: Time when the job is scheduled to
368
+ start.
369
+ :param str job_priority: Priority of the job.
370
+ :param bool job_dry_run: Flag indicating that the job will be executed
371
+ in dry-run mode. In this mode, OpenCGA will validate that all
372
+ parameters and prerequisites are correctly set for successful
373
+ execution, but the job will not actually run.
374
+ """
375
+
376
+ return self._post(category='analysis', resource='run', subcategory='clinical/interpreter/exomiser', data=data, **options)
377
+
378
+ def rd_interpreter(self, **options):
379
+ """
380
+ Rare disease interpretation analysis.
381
+ PATH: /{apiVersion}/analysis/clinical/interpreter/rd
382
+
383
+ :param str clinical_analysis_id: Clinical analysis ID.
384
+ :param str proband_id: Proband ID.
385
+ :param str family_id: Family ID.
386
+ :param str panel_ids: List of panel IDs (separated by commas).
387
+ :param str disorder_id: Disorder ID.
388
+ :param str config_file: RD interpretation configuration file
389
+ (otherwise the default one will be used).
390
+ :param str study: Study [[organization@]project:]study where study and
391
+ project can be either the ID or UUID.
392
+ """
393
+
394
+ return self._get(category='analysis', resource='rd', subcategory='clinical/interpreter', **options)
395
+
396
+ def run_interpreter_rd(self, data=None, **options):
397
+ """
398
+ Run interpretation analysis for rare diseases.
399
+ PATH: /{apiVersion}/analysis/clinical/interpreter/rd/run
400
+
401
+ :param dict data: Parameters to execute the rare disease
402
+ interpretation analysis. (REQUIRED)
403
+ :param str study: Study [[organization@]project:]study where study and
404
+ project can be either the ID or UUID.
405
+ :param str job_id: Job ID. It must be a unique string within the
406
+ study. An ID will be autogenerated automatically if not provided.
407
+ :param str job_description: Job description.
408
+ :param str job_depends_on: Comma separated list of existing job IDs
409
+ the job will depend on.
410
+ :param str job_tags: Job tags.
411
+ :param str job_scheduled_start_time: Time when the job is scheduled to
412
+ start.
413
+ :param str job_priority: Priority of the job.
414
+ :param bool job_dry_run: Flag indicating that the job will be executed
415
+ in dry-run mode. In this mode, OpenCGA will validate that all
416
+ parameters and prerequisites are correctly set for successful
417
+ execution, but the job will not actually run.
418
+ """
419
+
420
+ return self._post(category='analysis', resource='run', subcategory='clinical/interpreter/rd', data=data, **options)
421
+
422
+ def load(self, data=None, **options):
423
+ """
424
+ Load clinical analyses from a file.
425
+ PATH: /{apiVersion}/analysis/clinical/load
426
+
427
+ :param dict data: Parameters to load clinical analysis in OpenCGA
428
+ catalog from a file. (REQUIRED)
429
+ :param str study: Study [[organization@]project:]study where study and
430
+ project can be either the ID or UUID.
431
+ :param str job_id: Job ID. It must be a unique string within the
432
+ study. An ID will be autogenerated automatically if not provided.
433
+ :param str job_description: Job description.
434
+ :param str job_depends_on: Comma separated list of existing job IDs
435
+ the job will depend on.
436
+ :param str job_tags: Job tags.
437
+ :param str job_scheduled_start_time: Time when the job is scheduled to
438
+ start.
439
+ :param str job_priority: Priority of the job.
440
+ :param bool job_dry_run: Flag indicating that the job will be executed
441
+ in dry-run mode. In this mode, OpenCGA will validate that all
442
+ parameters and prerequisites are correctly set for successful
443
+ execution, but the job will not actually run.
444
+ """
445
+
446
+ return self._post(category='analysis', resource='load', subcategory='clinical', data=data, **options)
447
+
448
+ def aggregation_stats_rga(self, field, **options):
449
+ """
450
+ RGA aggregation stats.
451
+ PATH: /{apiVersion}/analysis/clinical/rga/aggregationStats
452
+
453
+ :param str field: List of fields separated by semicolons, e.g.:
454
+ clinicalSignificances;type. For nested fields use >>, e.g.:
455
+ type>>clinicalSignificances;knockoutType. (REQUIRED)
456
+ :param int limit: Number of results to be returned.
457
+ :param int skip: Number of results to skip.
458
+ :param str sample_id: Filter by sample id.
459
+ :param str individual_id: Filter by individual id.
460
+ :param str sex: Filter by sex.
461
+ :param str phenotypes: Filter by phenotypes.
462
+ :param str disorders: Filter by disorders.
463
+ :param str num_parents: Filter by the number of parents registered.
464
+ :param str gene_id: Filter by gene id.
465
+ :param str gene_name: Filter by gene name.
466
+ :param str chromosome: Filter by chromosome.
467
+ :param str start: Filter by start position.
468
+ :param str end: Filter by end position.
469
+ :param str transcript_id: Filter by transcript id.
470
+ :param str variants: Filter by variant id.
471
+ :param str db_snps: Filter by DB_SNP id.
472
+ :param str knockout_type: Filter by knockout type.
473
+ :param str filter: Filter by filter (PASS, NOT_PASS).
474
+ :param str type: Filter by variant type.
475
+ :param str clinical_significance: Filter by clinical significance.
476
+ :param str population_frequency: Filter by population frequency.
477
+ :param str consequence_type: Filter by consequence type.
478
+ :param str study: Study [[organization@]project:]study where study and
479
+ project can be either the ID or UUID.
480
+ """
481
+
482
+ options['field'] = field
483
+ return self._get(category='analysis', resource='aggregationStats', subcategory='clinical/rga', **options)
484
+
485
+ def query_rga_gene(self, **options):
486
+ """
487
+ Query gene RGA.
488
+ PATH: /{apiVersion}/analysis/clinical/rga/gene/query
489
+
490
+ :param str include: Fields included in the response, whole JSON path
491
+ must be provided.
492
+ :param str exclude: Fields excluded in the response, whole JSON path
493
+ must be provided.
494
+ :param int limit: Number of results to be returned.
495
+ :param int skip: Number of results to skip.
496
+ :param bool count: Get the total number of results matching the query.
497
+ Deactivated by default.
498
+ :param str include_individual: Include only the comma separated list
499
+ of individuals to the response.
500
+ :param int skip_individual: Number of individuals to skip.
501
+ :param int limit_individual: Limit number of individuals returned
502
+ (default: 1000).
503
+ :param str sample_id: Filter by sample id.
504
+ :param str individual_id: Filter by individual id.
505
+ :param str sex: Filter by sex.
506
+ :param str phenotypes: Filter by phenotypes.
507
+ :param str disorders: Filter by disorders.
508
+ :param str num_parents: Filter by the number of parents registered.
509
+ :param str gene_id: Filter by gene id.
510
+ :param str gene_name: Filter by gene name.
511
+ :param str chromosome: Filter by chromosome.
512
+ :param str start: Filter by start position.
513
+ :param str end: Filter by end position.
514
+ :param str transcript_id: Filter by transcript id.
515
+ :param str variants: Filter by variant id.
516
+ :param str db_snps: Filter by DB_SNP id.
517
+ :param str knockout_type: Filter by knockout type.
518
+ :param str filter: Filter by filter (PASS, NOT_PASS).
519
+ :param str type: Filter by variant type.
520
+ :param str clinical_significance: Filter by clinical significance.
521
+ :param str population_frequency: Filter by population frequency.
522
+ :param str consequence_type: Filter by consequence type.
523
+ :param str study: Study [[organization@]project:]study where study and
524
+ project can be either the ID or UUID.
525
+ """
526
+
527
+ return self._get(category='analysis', resource='query', subcategory='clinical/rga/gene', **options)
528
+
529
+ def summary_rga_gene(self, **options):
530
+ """
531
+ RGA gene summary stats.
532
+ PATH: /{apiVersion}/analysis/clinical/rga/gene/summary
533
+
534
+ :param int limit: Number of results to be returned.
535
+ :param int skip: Number of results to skip.
536
+ :param bool count: Get the total number of results matching the query.
537
+ Deactivated by default.
538
+ :param str sample_id: Filter by sample id.
539
+ :param str individual_id: Filter by individual id.
540
+ :param str sex: Filter by sex.
541
+ :param str phenotypes: Filter by phenotypes.
542
+ :param str disorders: Filter by disorders.
543
+ :param str num_parents: Filter by the number of parents registered.
544
+ :param str gene_id: Filter by gene id.
545
+ :param str gene_name: Filter by gene name.
546
+ :param str chromosome: Filter by chromosome.
547
+ :param str start: Filter by start position.
548
+ :param str end: Filter by end position.
549
+ :param str transcript_id: Filter by transcript id.
550
+ :param str variants: Filter by variant id.
551
+ :param str db_snps: Filter by DB_SNP id.
552
+ :param str knockout_type: Filter by knockout type.
553
+ :param str filter: Filter by filter (PASS, NOT_PASS).
554
+ :param str type: Filter by variant type.
555
+ :param str clinical_significance: Filter by clinical significance.
556
+ :param str population_frequency: Filter by population frequency.
557
+ :param str consequence_type: Filter by consequence type.
558
+ :param str study: Study [[organization@]project:]study where study and
559
+ project can be either the ID or UUID.
560
+ """
561
+
562
+ return self._get(category='analysis', resource='summary', subcategory='clinical/rga/gene', **options)
563
+
564
+ def run_rga_index(self, data=None, **options):
565
+ """
566
+ Generate Recessive Gene Analysis secondary index.
567
+ PATH: /{apiVersion}/analysis/clinical/rga/index/run
568
+
569
+ :param dict data: Recessive Gene Analysis index params. (REQUIRED)
570
+ :param str study: Study [[organization@]project:]study where study and
571
+ project can be either the ID or UUID.
572
+ :param str job_id: Job ID. It must be a unique string within the
573
+ study. An ID will be autogenerated automatically if not provided.
574
+ :param str job_description: Job description.
575
+ :param str job_depends_on: Comma separated list of existing job IDs
576
+ the job will depend on.
577
+ :param str job_tags: Job tags.
578
+ :param str job_scheduled_start_time: Time when the job is scheduled to
579
+ start.
580
+ :param str job_priority: Priority of the job.
581
+ :param bool job_dry_run: Flag indicating that the job will be executed
582
+ in dry-run mode. In this mode, OpenCGA will validate that all
583
+ parameters and prerequisites are correctly set for successful
584
+ execution, but the job will not actually run.
585
+ :param bool auxiliar_index: Index auxiliar collection to improve
586
+ performance assuming RGA is completely indexed.
587
+ """
588
+
589
+ return self._post(category='analysis', resource='run', subcategory='clinical/rga/index', data=data, **options)
590
+
591
+ def query_rga_individual(self, **options):
592
+ """
593
+ Query individual RGA.
594
+ PATH: /{apiVersion}/analysis/clinical/rga/individual/query
595
+
596
+ :param str include: Fields included in the response, whole JSON path
597
+ must be provided.
598
+ :param str exclude: Fields excluded in the response, whole JSON path
599
+ must be provided.
600
+ :param int limit: Number of results to be returned.
601
+ :param int skip: Number of results to skip.
602
+ :param bool count: Get the total number of results matching the query.
603
+ Deactivated by default.
604
+ :param str sample_id: Filter by sample id.
605
+ :param str individual_id: Filter by individual id.
606
+ :param str sex: Filter by sex.
607
+ :param str phenotypes: Filter by phenotypes.
608
+ :param str disorders: Filter by disorders.
609
+ :param str num_parents: Filter by the number of parents registered.
610
+ :param str gene_id: Filter by gene id.
611
+ :param str gene_name: Filter by gene name.
612
+ :param str chromosome: Filter by chromosome.
613
+ :param str start: Filter by start position.
614
+ :param str end: Filter by end position.
615
+ :param str transcript_id: Filter by transcript id.
616
+ :param str variants: Filter by variant id.
617
+ :param str db_snps: Filter by DB_SNP id.
618
+ :param str knockout_type: Filter by knockout type.
619
+ :param str filter: Filter by filter (PASS, NOT_PASS).
620
+ :param str type: Filter by variant type.
621
+ :param str clinical_significance: Filter by clinical significance.
622
+ :param str population_frequency: Filter by population frequency.
623
+ :param str consequence_type: Filter by consequence type.
624
+ :param str study: Study [[organization@]project:]study where study and
625
+ project can be either the ID or UUID.
626
+ """
627
+
628
+ return self._get(category='analysis', resource='query', subcategory='clinical/rga/individual', **options)
629
+
630
+ def summary_rga_individual(self, **options):
631
+ """
632
+ RGA individual summary stats.
633
+ PATH: /{apiVersion}/analysis/clinical/rga/individual/summary
634
+
635
+ :param int limit: Number of results to be returned.
636
+ :param int skip: Number of results to skip.
637
+ :param bool count: Get the total number of results matching the query.
638
+ Deactivated by default.
639
+ :param str sample_id: Filter by sample id.
640
+ :param str individual_id: Filter by individual id.
641
+ :param str sex: Filter by sex.
642
+ :param str phenotypes: Filter by phenotypes.
643
+ :param str disorders: Filter by disorders.
644
+ :param str num_parents: Filter by the number of parents registered.
645
+ :param str gene_id: Filter by gene id.
646
+ :param str gene_name: Filter by gene name.
647
+ :param str chromosome: Filter by chromosome.
648
+ :param str start: Filter by start position.
649
+ :param str end: Filter by end position.
650
+ :param str transcript_id: Filter by transcript id.
651
+ :param str variants: Filter by variant id.
652
+ :param str db_snps: Filter by DB_SNP id.
653
+ :param str knockout_type: Filter by knockout type.
654
+ :param str filter: Filter by filter (PASS, NOT_PASS).
655
+ :param str type: Filter by variant type.
656
+ :param str clinical_significance: Filter by clinical significance.
657
+ :param str population_frequency: Filter by population frequency.
658
+ :param str consequence_type: Filter by consequence type.
659
+ :param str study: Study [[organization@]project:]study where study and
660
+ project can be either the ID or UUID.
661
+ """
662
+
663
+ return self._get(category='analysis', resource='summary', subcategory='clinical/rga/individual', **options)
664
+
665
+ def query_rga_variant(self, **options):
666
+ """
667
+ Query variant RGA.
668
+ PATH: /{apiVersion}/analysis/clinical/rga/variant/query
669
+
670
+ :param str include: Fields included in the response, whole JSON path
671
+ must be provided.
672
+ :param str exclude: Fields excluded in the response, whole JSON path
673
+ must be provided.
674
+ :param int limit: Number of results to be returned.
675
+ :param int skip: Number of results to skip.
676
+ :param bool count: Get the total number of results matching the query.
677
+ Deactivated by default.
678
+ :param str include_individual: Include only the comma separated list
679
+ of individuals to the response.
680
+ :param int skip_individual: Number of individuals to skip.
681
+ :param int limit_individual: Limit number of individuals returned
682
+ (default: 1000).
683
+ :param str sample_id: Filter by sample id.
684
+ :param str individual_id: Filter by individual id.
685
+ :param str sex: Filter by sex.
686
+ :param str phenotypes: Filter by phenotypes.
687
+ :param str disorders: Filter by disorders.
688
+ :param str num_parents: Filter by the number of parents registered.
689
+ :param str gene_id: Filter by gene id.
690
+ :param str gene_name: Filter by gene name.
691
+ :param str chromosome: Filter by chromosome.
692
+ :param str start: Filter by start position.
693
+ :param str end: Filter by end position.
694
+ :param str transcript_id: Filter by transcript id.
695
+ :param str variants: Filter by variant id.
696
+ :param str db_snps: Filter by DB_SNP id.
697
+ :param str knockout_type: Filter by knockout type.
698
+ :param str filter: Filter by filter (PASS, NOT_PASS).
699
+ :param str type: Filter by variant type.
700
+ :param str clinical_significance: Filter by clinical significance.
701
+ :param str population_frequency: Filter by population frequency.
702
+ :param str consequence_type: Filter by consequence type.
703
+ :param str study: Study [[organization@]project:]study where study and
704
+ project can be either the ID or UUID.
705
+ """
706
+
707
+ return self._get(category='analysis', resource='query', subcategory='clinical/rga/variant', **options)
708
+
709
+ def summary_rga_variant(self, **options):
710
+ """
711
+ RGA variant summary stats.
712
+ PATH: /{apiVersion}/analysis/clinical/rga/variant/summary
713
+
714
+ :param int limit: Number of results to be returned.
715
+ :param int skip: Number of results to skip.
716
+ :param bool count: Get the total number of results matching the query.
717
+ Deactivated by default.
718
+ :param str sample_id: Filter by sample id.
719
+ :param str individual_id: Filter by individual id.
720
+ :param str sex: Filter by sex.
721
+ :param str phenotypes: Filter by phenotypes.
722
+ :param str disorders: Filter by disorders.
723
+ :param str num_parents: Filter by the number of parents registered.
724
+ :param str gene_id: Filter by gene id.
725
+ :param str gene_name: Filter by gene name.
726
+ :param str chromosome: Filter by chromosome.
727
+ :param str start: Filter by start position.
728
+ :param str end: Filter by end position.
729
+ :param str transcript_id: Filter by transcript id.
730
+ :param str variants: Filter by variant id.
731
+ :param str db_snps: Filter by DB_SNP id.
732
+ :param str knockout_type: Filter by knockout type.
733
+ :param str filter: Filter by filter (PASS, NOT_PASS).
734
+ :param str type: Filter by variant type.
735
+ :param str clinical_significance: Filter by clinical significance.
736
+ :param str population_frequency: Filter by population frequency.
737
+ :param str consequence_type: Filter by consequence type.
738
+ :param str study: Study [[organization@]project:]study where study and
739
+ project can be either the ID or UUID.
740
+ """
741
+
742
+ return self._get(category='analysis', resource='summary', subcategory='clinical/rga/variant', **options)
743
+
744
+ def search(self, **options):
745
+ """
746
+ Clinical analysis search.
747
+ PATH: /{apiVersion}/analysis/clinical/search
748
+
749
+ :param str include: Fields included in the response, whole JSON path
750
+ must be provided.
751
+ :param str exclude: Fields excluded in the response, whole JSON path
752
+ must be provided.
753
+ :param int limit: Number of results to be returned.
754
+ :param int skip: Number of results to skip.
755
+ :param bool count: Get the total number of results matching the query.
756
+ Deactivated by default.
757
+ :param bool flatten_annotations: Flatten the annotations?.
758
+ :param str study: Study [[organization@]project:]study where study and
759
+ project can be either the ID or UUID.
760
+ :param str id: Comma separated list of Clinical Analysis IDs up to a
761
+ maximum of 100. Also admits basic regular expressions using the
762
+ operator '~', i.e. '~{perl-regex}' e.g. '~value' for case
763
+ sensitive, '~/value/i' for case insensitive search.
764
+ :param str uuid: Comma separated list of Clinical Analysis UUIDs up to
765
+ a maximum of 100.
766
+ :param str type: Clinical Analysis type.
767
+ :param str disorder: Clinical Analysis disorder. Also admits basic
768
+ regular expressions using the operator '~', i.e. '~{perl-regex}'
769
+ e.g. '~value' for case sensitive, '~/value/i' for case insensitive
770
+ search.
771
+ :param str files: Clinical Analysis files.
772
+ :param str sample: Sample associated to the proband or any member of a
773
+ family.
774
+ :param str individual: Proband or any member of a family.
775
+ :param str proband: Clinical Analysis proband.
776
+ :param str proband_samples: Clinical Analysis proband samples.
777
+ :param str family: Clinical Analysis family.
778
+ :param str family_members: Clinical Analysis family members.
779
+ :param str family_member_samples: Clinical Analysis family members
780
+ samples.
781
+ :param str panels: Clinical Analysis panels.
782
+ :param bool locked: Locked Clinical Analyses.
783
+ :param str analyst_id: Clinical Analysis analyst id.
784
+ :param str priority: Clinical Analysis priority.
785
+ :param str flags: Clinical Analysis flags.
786
+ :param str creation_date: Clinical Analysis Creation date. Format:
787
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
788
+ :param str modification_date: Clinical Analysis Modification date.
789
+ Format: yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
790
+ :param str due_date: Clinical Analysis due date. Format:
791
+ yyyyMMddHHmmss. Examples: >2018, 2017-2018, <201805.
792
+ :param str quality_control_summary: Clinical Analysis quality control
793
+ summary.
794
+ :param str release: Release when it was created.
795
+ :param int snapshot: Snapshot value (Latest version of the entry in
796
+ the specified release).
797
+ :param str status: Filter by status.
798
+ :param str internal_status: Filter by internal status.
799
+ :param str annotation: Annotation filters. Example:
800
+ age>30;gender=FEMALE. For more information, please visit
801
+ http://docs.opencb.org/display/opencga/AnnotationSets+1.4.0.
802
+ :param bool deleted: Boolean to retrieve deleted entries.
803
+ """
804
+
805
+ return self._get(category='analysis', resource='search', subcategory='clinical', **options)
806
+
807
+ def query_variant(self, **options):
808
+ """
809
+ Fetch clinical variants.
810
+ PATH: /{apiVersion}/analysis/clinical/variant/query
811
+
812
+ :param str include: Fields included in the response, whole JSON path
813
+ must be provided.
814
+ :param str exclude: Fields excluded in the response, whole JSON path
815
+ must be provided.
816
+ :param int limit: Number of results to be returned.
817
+ :param int skip: Number of results to skip.
818
+ :param bool count: Get the total number of results matching the query.
819
+ Deactivated by default.
820
+ :param bool approximate_count: Get an approximate count, instead of an
821
+ exact total count. Reduces execution time.
822
+ :param int approximate_count_sampling_size: Sampling size to get the
823
+ approximate count. Larger values increase accuracy but also
824
+ increase execution time.
825
+ :param str saved_filter: Use a saved filter at User level.
826
+ :param str include_interpretation: Interpretation ID to include the
827
+ fields related to this interpretation.
828
+ :param str id: List of variant IDs in the format chrom:start:ref:alt,
829
+ e.g. 19:7177679:C:T.
830
+ :param str region: List of regions, these can be just a single
831
+ chromosome name or regions in the format chr:start-end, e.g.:
832
+ 2,3:100000-200000.
833
+ :param str type: List of types, accepted values are SNV, MNV, INDEL,
834
+ SV, COPY_NUMBER, COPY_NUMBER_LOSS, COPY_NUMBER_GAIN, INSERTION,
835
+ DELETION, DUPLICATION, TANDEM_DUPLICATION, BREAKEND, e.g.
836
+ SNV,INDEL.
837
+ :param str study: Filter variants from the given studies, these can be
838
+ either the numeric ID or the alias with the format
839
+ organization@project:study.
840
+ :param str file: Filter variants from the files specified. This will
841
+ set includeFile parameter when not provided.
842
+ :param str filter: Specify the FILTER for any of the files. If 'file'
843
+ filter is provided, will match the file and the filter. e.g.:
844
+ PASS,LowGQX.
845
+ :param str qual: Specify the QUAL for any of the files. If 'file'
846
+ filter is provided, will match the file and the qual. e.g.: >123.4.
847
+ :param str file_data: Filter by file data (i.e. FILTER, QUAL and INFO
848
+ columns from VCF file). [{file}:]{key}{op}{value}[,;]* . If no file
849
+ is specified, will use all files from 'file' filter. e.g. AN>200 or
850
+ file_1.vcf:AN>200;file_2.vcf:AN<10 . Many fields can be combined.
851
+ e.g. file_1.vcf:AN>200;DB=true;file_2.vcf:AN<10,FILTER=PASS,LowDP.
852
+ :param str sample: Filter variants by sample genotype. This will
853
+ automatically set 'includeSample' parameter when not provided. This
854
+ filter accepts multiple 3 forms: 1) List of samples: Samples that
855
+ contain the main variant. Accepts AND ';' and OR ',' operators.
856
+ e.g. HG0097,HG0098 . 2) List of samples with genotypes:
857
+ {sample}:{gt1},{gt2}. Accepts AND ';' and OR ',' operators. e.g.
858
+ HG0097:0/0;HG0098:0/1,1/1 . Unphased genotypes (e.g. 0/1, 1/1) will
859
+ also include phased genotypes (e.g. 0|1, 1|0, 1|1), but not vice
860
+ versa. When filtering by multi-allelic genotypes, any secondary
861
+ allele will match, regardless of its position e.g. 1/2 will match
862
+ with genotypes 1/2, 1/3, 1/4, .... Genotype aliases accepted:
863
+ HOM_REF, HOM_ALT, HET, HET_REF, HET_ALT, HET_MISS and MISS e.g.
864
+ HG0097:HOM_REF;HG0098:HET_REF,HOM_ALT . 3) Sample with segregation
865
+ mode: {sample}:{segregation}. Only one sample accepted.Accepted
866
+ segregation modes: [ autosomalDominant, autosomalRecessive,
867
+ XLinkedDominant, XLinkedRecessive, YLinked, mitochondrial, deNovo,
868
+ deNovoStrict, mendelianError, compoundHeterozygous ]. Value is case
869
+ insensitive. e.g. HG0097:DeNovo Sample must have parents defined
870
+ and indexed. .
871
+ :param str sample_data: Filter by any SampleData field from samples.
872
+ [{sample}:]{key}{op}{value}[,;]* . If no sample is specified, will
873
+ use all samples from 'sample' or 'genotype' filter. e.g. DP>200 or
874
+ HG0097:DP>200,HG0098:DP<10 . Many FORMAT fields can be combined.
875
+ e.g. HG0097:DP>200;GT=1/1,0/1,HG0098:DP<10.
876
+ :param str sample_annotation: Selects some samples using metadata
877
+ information from Catalog. e.g.
878
+ age>20;phenotype=hpo:123,hpo:456;name=smith.
879
+ :param str cohort: Select variants with calculated stats for the
880
+ selected cohorts.
881
+ :param str cohort_stats_ref: Reference Allele Frequency:
882
+ [{study:}]{cohort}[<|>|<=|>=]{number}. e.g. ALL<=0.4.
883
+ :param str cohort_stats_alt: Alternate Allele Frequency:
884
+ [{study:}]{cohort}[<|>|<=|>=]{number}. e.g. ALL<=0.4.
885
+ :param str cohort_stats_maf: Minor Allele Frequency:
886
+ [{study:}]{cohort}[<|>|<=|>=]{number}. e.g. ALL<=0.4.
887
+ :param str cohort_stats_mgf: Minor Genotype Frequency:
888
+ [{study:}]{cohort}[<|>|<=|>=]{number}. e.g. ALL<=0.4.
889
+ :param str cohort_stats_pass: Filter PASS frequency:
890
+ [{study:}]{cohort}[<|>|<=|>=]{number}. e.g. ALL>0.8.
891
+ :param str missing_alleles: Number of missing alleles:
892
+ [{study:}]{cohort}[<|>|<=|>=]{number}.
893
+ :param str missing_genotypes: Number of missing genotypes:
894
+ [{study:}]{cohort}[<|>|<=|>=]{number}.
895
+ :param str score: Filter by variant score:
896
+ [{study:}]{score}[<|>|<=|>=]{number}.
897
+ :param str family: Filter variants where any of the samples from the
898
+ given family contains the variant (HET or HOM_ALT).
899
+ :param str family_disorder: Specify the disorder to use for the family
900
+ segregation.
901
+ :param str family_segregation: Filter by segregation mode from a given
902
+ family. Accepted values: [ autosomalDominant, autosomalRecessive,
903
+ XLinkedDominant, XLinkedRecessive, YLinked, mitochondrial, deNovo,
904
+ deNovoStrict, mendelianError, compoundHeterozygous ].
905
+ :param str family_members: Sub set of the members of a given family.
906
+ :param str family_proband: Specify the proband child to use for the
907
+ family segregation.
908
+ :param str gene: List of genes, most gene IDs are accepted (HGNC,
909
+ Ensembl gene, ...). This is an alias to 'xref' parameter.
910
+ :param str ct: List of SO consequence types, e.g.
911
+ missense_variant,stop_lost or SO:0001583,SO:0001578. Accepts
912
+ aliases 'loss_of_function' and 'protein_altering'.
913
+ :param str xref: List of any external reference, these can be genes,
914
+ proteins or variants. Accepted IDs include HGNC, Ensembl genes,
915
+ dbSNP, ClinVar, HPO, Cosmic, HGVS ...
916
+ :param str biotype: List of biotypes, e.g. protein_coding.
917
+ :param str protein_substitution: Protein substitution scores include
918
+ SIFT and PolyPhen. You can query using the score
919
+ {protein_score}[<|>|<=|>=]{number} or the description
920
+ {protein_score}[~=|=]{description} e.g. polyphen>0.1,sift=tolerant.
921
+ :param str conservation: Filter by conservation score:
922
+ {conservation_score}[<|>|<=|>=]{number} e.g.
923
+ phastCons>0.5,phylop<0.1,gerp>0.1.
924
+ :param str population_frequency_alt: Alternate Population Frequency:
925
+ {study}:{population}[<|>|<=|>=]{number}. e.g. 1000G:ALL<0.01.
926
+ :param str population_frequency_ref: Reference Population Frequency:
927
+ {study}:{population}[<|>|<=|>=]{number}. e.g. 1000G:ALL<0.01.
928
+ :param str population_frequency_maf: Population minor allele
929
+ frequency: {study}:{population}[<|>|<=|>=]{number}. e.g.
930
+ 1000G:ALL<0.01.
931
+ :param str transcript_flag: List of transcript flags. e.g. canonical,
932
+ CCDS, basic, LRG, MANE Select, MANE Plus Clinical, EGLH_HaemOnc,
933
+ TSO500.
934
+ :param str gene_trait_id: List of gene trait association id. e.g.
935
+ 'umls:C0007222' , 'OMIM:269600'.
936
+ :param str go: List of GO (Gene Ontology) terms. e.g. 'GO:0002020'.
937
+ :param str expression: List of tissues of interest. e.g. 'lung'.
938
+ :param str protein_keyword: List of Uniprot protein variant annotation
939
+ keywords.
940
+ :param str drug: List of drug names.
941
+ :param str functional_score: Functional score:
942
+ {functional_score}[<|>|<=|>=]{number} e.g. cadd_scaled>5.2 ,
943
+ cadd_raw<=0.3.
944
+ :param str clinical: Clinical source: clinvar, cosmic.
945
+ :param str clinical_significance: Clinical significance: benign,
946
+ likely_benign, likely_pathogenic, pathogenic.
947
+ :param bool clinical_confirmed_status: Clinical confirmed status.
948
+ :param str custom_annotation: Custom annotation:
949
+ {key}[<|>|<=|>=]{number} or {key}[~=|=]{text}.
950
+ :param str panel: Filter by genes from the given disease panel.
951
+ :param str panel_mode_of_inheritance: Filter genes from specific
952
+ panels that match certain mode of inheritance. Accepted values : [
953
+ autosomalDominant, autosomalRecessive, XLinkedDominant,
954
+ XLinkedRecessive, YLinked, mitochondrial, deNovo, mendelianError,
955
+ compoundHeterozygous ].
956
+ :param str panel_confidence: Filter genes from specific panels that
957
+ match certain confidence. Accepted values : [ high, medium, low,
958
+ rejected ].
959
+ :param str panel_role_in_cancer: Filter genes from specific panels
960
+ that match certain role in cancer. Accepted values : [ both,
961
+ oncogene, tumorSuppressorGene, fusion ].
962
+ :param str panel_feature_type: Filter elements from specific panels by
963
+ type. Accepted values : [ gene, region, str, variant ].
964
+ :param bool panel_intersection: Intersect panel genes and regions with
965
+ given genes and regions from que input query. This will prevent
966
+ returning variants from regions out of the panel.
967
+ :param str trait: List of traits, based on ClinVar, HPO, COSMIC, i.e.:
968
+ IDs, histologies, descriptions,...
969
+ :param str ci_status_id: Clinical interpretation status ID (or list of
970
+ IDs separated by commas). Valid values: NOT_STARTED, ACTIVE, DONE,
971
+ CLOSED.
972
+ """
973
+
974
+ return self._get(category='analysis', resource='query', subcategory='clinical/variant', **options)
975
+
976
+ def acl(self, clinical_analyses, **options):
977
+ """
978
+ Returns the acl of the clinical analyses. If member is provided, it
979
+ will only return the acl for the member.
980
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalyses}/acl
981
+
982
+ :param str clinical_analyses: Comma separated list of clinical
983
+ analysis IDs or names up to a maximum of 100. (REQUIRED)
984
+ :param str study: Study [[organization@]project:]study where study and
985
+ project can be either the ID or UUID.
986
+ :param str member: User or group ID.
987
+ :param bool silent: Boolean to retrieve all possible entries that are
988
+ queried for, false to raise an exception whenever one of the
989
+ entries looked for cannot be shown for whichever reason.
990
+ """
991
+
992
+ return self._get(category='analysis', resource='acl', subcategory='clinical', second_query_id=clinical_analyses, **options)
993
+
994
+ def delete(self, clinical_analyses, **options):
995
+ """
996
+ Delete clinical analyses.
997
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalyses}/delete
998
+
999
+ :param str clinical_analyses: Comma separated list of clinical
1000
+ analysis IDs or names up to a maximum of 100. (REQUIRED)
1001
+ :param str study: Study [[organization@]project:]study where study and
1002
+ project can be either the ID or UUID.
1003
+ :param bool force: Force deletion if the ClinicalAnalysis contains
1004
+ interpretations or is locked.
1005
+ """
1006
+
1007
+ return self._delete(category='analysis', resource='delete', subcategory='clinical', second_query_id=clinical_analyses, **options)
1008
+
1009
+ def update(self, clinical_analyses, data=None, **options):
1010
+ """
1011
+ Update clinical analysis attributes.
1012
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalyses}/update
1013
+
1014
+ :param dict data: JSON containing clinical analysis information.
1015
+ (REQUIRED)
1016
+ :param str clinical_analyses: Comma separated list of clinical
1017
+ analysis IDs. (REQUIRED)
1018
+ :param str include: Fields included in the response, whole JSON path
1019
+ must be provided.
1020
+ :param str exclude: Fields excluded in the response, whole JSON path
1021
+ must be provided.
1022
+ :param str study: Study [[organization@]project:]study where study and
1023
+ project can be either the ID or UUID.
1024
+ :param str comments_action: Action to be performed if the array of
1025
+ comments is being updated. Allowed values: ['ADD REMOVE REPLACE']
1026
+ :param str flags_action: Action to be performed if the array of flags
1027
+ is being updated. Allowed values: ['ADD SET REMOVE']
1028
+ :param str analysts_action: Action to be performed if the array of
1029
+ analysts is being updated. Allowed values: ['ADD SET REMOVE']
1030
+ :param str files_action: Action to be performed if the array of files
1031
+ is being updated. Allowed values: ['ADD SET REMOVE']
1032
+ :param str panels_action: Action to be performed if the array of
1033
+ panels is being updated. Allowed values: ['ADD SET REMOVE']
1034
+ :param str annotation_sets_action: Action to be performed if the array
1035
+ of annotationSets is being updated. Allowed values: ['ADD SET
1036
+ REMOVE']
1037
+ :param bool include_result: Flag indicating to include the created or
1038
+ updated document result in the response.
1039
+ """
1040
+
1041
+ return self._post(category='analysis', resource='update', subcategory='clinical', second_query_id=clinical_analyses, data=data, **options)
1042
+
1043
+ def update_annotation_sets_annotations(self, clinical_analysis, annotation_set, data=None, **options):
1044
+ """
1045
+ Update annotations from an annotationSet.
1046
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/annotationSets/{annotationSet}/annotations/update
1047
+
1048
+ :param str annotation_set: AnnotationSet ID to be updated. (REQUIRED)
1049
+ :param str clinical_analysis: Clinical analysis ID. (REQUIRED)
1050
+ :param str study: Study [[organization@]project:]study where study and
1051
+ project can be either the ID or UUID.
1052
+ :param str action: Action to be performed: ADD to add new annotations;
1053
+ REPLACE to replace the value of an already existing annotation; SET
1054
+ to set the new list of annotations removing any possible old
1055
+ annotations; REMOVE to remove some annotations; RESET to set some
1056
+ annotations to the default value configured in the corresponding
1057
+ variables of the VariableSet if any. Allowed values: ['ADD SET
1058
+ REMOVE RESET REPLACE']
1059
+ :param dict data: Json containing the map of annotations when the
1060
+ action is ADD, SET or REPLACE, a json with only the key 'remove'
1061
+ containing the comma separated variables to be removed as a value
1062
+ when the action is REMOVE or a json with only the key 'reset'
1063
+ containing the comma separated variables that will be set to the
1064
+ default value when the action is RESET.
1065
+ """
1066
+
1067
+ return self._post(category='analysis/clinical', resource='annotations/update', query_id=clinical_analysis, subcategory='annotationSets', second_query_id=annotation_set, data=data, **options)
1068
+
1069
+ def info(self, clinical_analysis, **options):
1070
+ """
1071
+ Clinical analysis info.
1072
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/info
1073
+
1074
+ :param str clinical_analysis: Comma separated list of clinical
1075
+ analysis IDs or names up to a maximum of 100. (REQUIRED)
1076
+ :param str include: Fields included in the response, whole JSON path
1077
+ must be provided.
1078
+ :param str exclude: Fields excluded in the response, whole JSON path
1079
+ must be provided.
1080
+ :param bool flatten_annotations: Flatten the annotations?.
1081
+ :param str study: Study [[organization@]project:]study where study and
1082
+ project can be either the ID or UUID.
1083
+ :param str version: Comma separated list of clinical versions. 'all'
1084
+ to get all the clinical versions. Not supported if multiple
1085
+ clinical ids are provided.
1086
+ :param bool deleted: Boolean to retrieve deleted entries.
1087
+ """
1088
+
1089
+ return self._get(category='analysis', resource='info', subcategory='clinical', second_query_id=clinical_analysis, **options)
1090
+
1091
+ def create_interpretation(self, clinical_analysis, data=None, **options):
1092
+ """
1093
+ Create a new Interpretation.
1094
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/interpretation/create
1095
+
1096
+ :param dict data: JSON containing clinical interpretation information.
1097
+ (REQUIRED)
1098
+ :param str clinical_analysis: Clinical analysis ID. (REQUIRED)
1099
+ :param str include: Fields included in the response, whole JSON path
1100
+ must be provided.
1101
+ :param str exclude: Fields excluded in the response, whole JSON path
1102
+ must be provided.
1103
+ :param str study: [[organization@]project:]study id.
1104
+ :param str set_as: Set interpretation as. Allowed values: ['PRIMARY
1105
+ SECONDARY']
1106
+ :param bool include_result: Flag indicating to include the created or
1107
+ updated document result in the response.
1108
+ """
1109
+
1110
+ return self._post(category='analysis/clinical', resource='create', query_id=clinical_analysis, subcategory='interpretation', data=data, **options)
1111
+
1112
+ def clear_interpretation(self, clinical_analysis, interpretations, **options):
1113
+ """
1114
+ Clear the fields of the main interpretation of the Clinical Analysis.
1115
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/interpretation/{interpretations}/clear
1116
+
1117
+ :param str clinical_analysis: Clinical analysis ID. (REQUIRED)
1118
+ :param str interpretations: Interpretation IDs of the Clinical
1119
+ Analysis. (REQUIRED)
1120
+ :param str study: [[organization@]project:]study ID.
1121
+ """
1122
+
1123
+ return self._post(category='analysis/clinical', resource='clear', query_id=clinical_analysis, subcategory='interpretation', second_query_id=interpretations, **options)
1124
+
1125
+ def delete_interpretation(self, clinical_analysis, interpretations, **options):
1126
+ """
1127
+ Delete interpretation.
1128
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/interpretation/{interpretations}/delete
1129
+
1130
+ :param str interpretations: Interpretation IDs of the Clinical
1131
+ Analysis. (REQUIRED)
1132
+ :param str clinical_analysis: Clinical analysis ID. (REQUIRED)
1133
+ :param str study: [[organization@]project:]study ID.
1134
+ :param str set_as_primary: Interpretation id to set as primary from
1135
+ the list of secondaries in case of deleting the actual primary one.
1136
+ """
1137
+
1138
+ return self._delete(category='analysis/clinical', resource='delete', query_id=clinical_analysis, subcategory='interpretation', second_query_id=interpretations, **options)
1139
+
1140
+ def revert_interpretation(self, clinical_analysis, interpretation, version, **options):
1141
+ """
1142
+ Revert to a previous interpretation version.
1143
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/interpretation/{interpretation}/revert
1144
+
1145
+ :param int version: Version to revert to. (REQUIRED)
1146
+ :param str interpretation: Interpretation ID. (REQUIRED)
1147
+ :param str clinical_analysis: Clinical analysis ID. (REQUIRED)
1148
+ :param str study: [[organization@]project:]study ID.
1149
+ """
1150
+
1151
+ options['version'] = version
1152
+ return self._post(category='analysis/clinical', resource='revert', query_id=clinical_analysis, subcategory='interpretation', second_query_id=interpretation, **options)
1153
+
1154
+ def update_interpretation(self, clinical_analysis, interpretation, data=None, **options):
1155
+ """
1156
+ Update interpretation fields.
1157
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/interpretation/{interpretation}/update
1158
+
1159
+ :param dict data: JSON containing clinical interpretation information.
1160
+ (REQUIRED)
1161
+ :param str interpretation: Interpretation ID. (REQUIRED)
1162
+ :param str clinical_analysis: Clinical analysis ID. (REQUIRED)
1163
+ :param str include: Fields included in the response, whole JSON path
1164
+ must be provided.
1165
+ :param str exclude: Fields excluded in the response, whole JSON path
1166
+ must be provided.
1167
+ :param str study: [[organization@]project:]study ID.
1168
+ :param str primary_findings_action: Action to be performed if the
1169
+ array of primary findings is being updated. Allowed values: ['ADD
1170
+ SET REMOVE REPLACE']
1171
+ :param str methods_action: Action to be performed if the array of
1172
+ methods is being updated. Allowed values: ['ADD SET REMOVE']
1173
+ :param str secondary_findings_action: Action to be performed if the
1174
+ array of secondary findings is being updated. Allowed values: ['ADD
1175
+ SET REMOVE REPLACE']
1176
+ :param str comments_action: Action to be performed if the array of
1177
+ comments is being updated. To REMOVE or REPLACE, the date will need
1178
+ to be provided to identify the comment. Allowed values: ['ADD
1179
+ REMOVE REPLACE']
1180
+ :param str panels_action: Action to be performed if the array of
1181
+ panels is being updated. Allowed values: ['ADD SET REMOVE']
1182
+ :param str set_as: Set interpretation as. Allowed values: ['PRIMARY
1183
+ SECONDARY']
1184
+ :param bool include_result: Flag indicating to include the created or
1185
+ updated document result in the response.
1186
+ """
1187
+
1188
+ return self._post(category='analysis/clinical', resource='update', query_id=clinical_analysis, subcategory='interpretation', second_query_id=interpretation, data=data, **options)
1189
+
1190
+ def update_report(self, clinical_analysis, data=None, **options):
1191
+ """
1192
+ Update clinical analysis report.
1193
+ PATH: /{apiVersion}/analysis/clinical/{clinicalAnalysis}/report/update
1194
+
1195
+ :param dict data: JSON containing clinical report information.
1196
+ (REQUIRED)
1197
+ :param str clinical_analysis: Clinical analysis ID. (REQUIRED)
1198
+ :param str include: Fields included in the response, whole JSON path
1199
+ must be provided.
1200
+ :param str exclude: Fields excluded in the response, whole JSON path
1201
+ must be provided.
1202
+ :param str study: Study [[organization@]project:]study where study and
1203
+ project can be either the ID or UUID.
1204
+ :param str comments_action: Action to be performed if the array of
1205
+ comments is being updated. Allowed values: ['ADD REMOVE REPLACE']
1206
+ :param str supporting_evidences_action: Action to be performed if the
1207
+ array of supporting evidences is being updated. Allowed values:
1208
+ ['ADD SET REMOVE']
1209
+ :param str files_action: Action to be performed if the array of files
1210
+ is being updated. Allowed values: ['ADD SET REMOVE']
1211
+ :param bool include_result: Flag indicating to include the created or
1212
+ updated document result in the response.
1213
+ """
1214
+
1215
+ return self._post(category='analysis/clinical', resource='update', query_id=clinical_analysis, subcategory='report', data=data, **options)
1216
+