Skip to content
Snippets Groups Projects
Commit 17e0fb84 authored by Blaise Li's avatar Blaise Li
Browse files

Accomodate for possible absence of small RNA type.

parent ada7124c
No related branches found
No related tags found
No related merge requests found
...@@ -2059,7 +2059,9 @@ def source_small_RNA_counts(wildcards): ...@@ -2059,7 +2059,9 @@ def source_small_RNA_counts(wildcards):
def make_tag_association(dfs, tag): def make_tag_association(dfs, tag):
"""Associates a tag "tag" to the union of the indices of dataframes *dfs*.""" """Associates a tag "tag" to the union of the indices of dataframes *dfs*."""
idx = reduce(union, (df.index for df in dfs)) idx = reduce(union, (df.index for df in dfs))
return pd.DataFrame(list(zip(idx, repeat(tag)))).set_index(0) if len(idx):
return pd.DataFrame(list(zip(idx, repeat(tag)))).set_index(0)
return pd.DataFrame()
# Could we use biotype instead? # Could we use biotype instead?
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment