def _get_hd_args(path, high_dim_node, annotation):
"""
Create dict with meta tags that belong to a certain high dimensional node.
"""
map_file = high_dim_node.sample_mapping
s = map_file.slice_path(path).iloc[:, 5].unique()
t = map_file.slice_path(path).iloc[:, 6].unique()
hd_args = {'hd_sample': ', '.join(s.astype(str)) if pd.notnull(s[0]) else '',
'hd_tissue': ', '.join(t.astype(str)) if pd.notnull(t[0]) else '',
'hd_type': Mappings.annotation_data_types.get(high_dim_node.params.datatype),
}
if annotation:
hd_args.update({'pl_marker_type': annotation.marker_type,
'pl_genome_build': annotation.params.get('GENOME_RELEASE', ''),
'pl_title': annotation.params.get('TITLE', ''),
'pl_id': annotation.platform})
return hd_args
评论列表
文章目录