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):
def make_tag_association(dfs, tag):
"""Associates a tag "tag" to the union of the indices of dataframes *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?
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment