Commits

Davide Cittaro committed 431a8df

bugfix in append

Comments (0)

Files changed (1)

 for rg in bamh.header['RG']:
   if extract_by_rg:
     if len(samples)==0 or rg['ID'] in samples:
-      tokeep.append([rg['ID']])
+      tokeep.append(rg['ID'])
       rg2sm[rg['ID']] = rg['ID']
   else:
     if len(samples)==0 or rg['SM'] in samples:
-      tokeep.append([rg['SM'])
+      tokeep.append(rg['SM'])
       rg2sm[rg['ID']] = rg['SM']
 
 if not tokeep:
   sample2fo[sm].close()            
 
 
+