Skip to main content
7 events
when toggle format what by license comment
Nov 19, 2020 at 6:43 vote accept CommunityBot
Nov 19, 2020 at 6:43
Nov 18, 2020 at 6:54 comment added Sentox That's what I mean by using strs = dr.fieldnames[1:]. A DictReader has a property called fieldnames that will give you a list of just the field names. Slice it with [1:] to drop "name". Your algorithm currently isn't counting the sequences correctly so at this point you will need to use debug50 and start stepping through your code to figure out what's going wrong.
Nov 18, 2020 at 6:16 comment added user31128 So, how can I access the names? By the way, I'm always getting 'no match'. And the errors have gone, so thanks for that
Nov 17, 2020 at 20:55 comment added Sentox You pass your open file to two readers and call next() on the reader object. Then when you go to utilise the DictReader, it pulls the field names from the second row instead of the first. Scrap the reader and use strs = dr.fieldnames[1:].
Nov 17, 2020 at 13:08 comment added user31128 why is there keyerror for 'AGATC'?
Nov 17, 2020 at 10:02 comment added Sentox argv will work because of the from sys import * line, which will literally important all names from sys (except those beginning with an underscore). Its use is generally frowned upon since it can cause confusion, but it will work here.
Nov 17, 2020 at 9:37 history answered David Rosendorf CC BY-SA 4.0