I've noticed that there is some missuse of markdown code formatting
here. Before I go around editing it out, it would be good to come to a consensus on when it is appropriate.
In my opinion, the following is true:
Appropriate
Code blocks (obviously), e.g.
def id_func(x): if x.featuretype == 'gene': new_id = x.attributes['ID'][0] elif x.featuretype == 'CDS': new_id = '-'.join( [x.attributes['ID'][0], x.seqid, str(x.start), str(x.end)] ) return new_id
Error messages and other formatted text output, e.g.
print("1" + '"' + str(fastaIdx) + '"' + '"' + str(mrna_id) + "'" + db.strand()) AttributeError: 'FeatureDB' object has no attribute 'strand'
Formatted data, e.g.
Seq_18 Liftoff gene 653259 653653 . + . ID=QZVMAR_2781_gene_1 Seq_18 Liftoff CDS 653259 653334 . + . ID=Seq_8_Seq_8_Manual.BlastoST7C_030513:00:54_1;Parent=QZVMAR_2781_gene_1 Seq_18 Liftoff CDS 653370 653458 . + . ID=Seq_8_Seq_8_Manual.BlastoST7C_030513:00:54_1;Parent=QZVMAR_2781_gene_1 Seq_18 Liftoff CDS 653489 653543 . + . ID=Seq_8_Seq_8_Manual.BlastoST7C_030513:00:54_1;Parent=QZVMAR_2781_gene_1 Seq_18 Liftoff CDS 653577 653653 . + . ID=Seq_8_Seq_8_Manual.BlastoST7C_030513:00:54_1;Parent=QZVMAR_2781_gene_1
Referring to inline function names, e.g.
You should only use
printf
when....
Not appropriate
- When
emphasising
words in a sentence - When referring to the name of a piece of software
pandas
or programming languagepython
- Anything else that isn't covered by the above points
Up for discussion
- When referring to filenames
test.fastq
Does the comminity agree? Are there any additions or removals that people think are appropriate?