[Biopython-dev] [Bug 2381] translate and transcibe methods for the Seq object (in Bio.Seq)

bugzilla-daemon at portal.open-bio.org bugzilla-daemon at portal.open-bio.org
Tue Nov 4 13:57:48 UTC 2008


http://bugzilla.open-bio.org/show_bug.cgi?id=2381





------- Comment #30 from lpritc at scri.sari.ac.uk  2008-11-04 08:57 EST -------
(In reply to comment #29)
> (In reply to comment #28)
> > (In reply to comment #27)
> > > Created an attachment (id=1032)
 --> (http://bugzilla.open-bio.org/attachment.cgi?id=1032&action=view) [details] [details] [details]
> > > Docstring:
> > > 
> > >         init - Boolean, defaults to False.  Should translation check the
> > >                first codon is a valid initiation (start) codon and translate
> > >                it as methionine (M)?  If False, nothing special is done with
> > >                the first codon.
> > 
> > I don't like the name 'init' :( it would be better to use an argument with the
> > word 'force' in it. E.g.: force_has_coding, force_first_position, etc..
> 
> Maybe - but I don't think force_has_coding, force_first_position are any
> clearer, and they are very long.  Do you like "with_start_codon" or
> "with_init_codon"?

I think that there are two key things that are going on as a result of this
setting being True:

1) The first codon (starting at position 0) of the nucleotide sequence is being
checked as a valid initiation codon

2) If it is such a valid codon, the translated aa is Met (because this is what
happens biologically).

It's quite a complicated concept, and if we wanted to be completely explicit,
an option called 'assert_first_codon_is_initiation_and_translate_to_met' would
be clear, but would be far too long to be sensible.  Most other shorter options
are either ambiguous, misleading, or ambiguously misleading - largely because
people will assume that the term means what they want it to mean instead of
what it does, as described below:

> If it have been called "start" or "from_start" or "start_codon" the meaning
> isn't clear either - you might "start" or expect "from_start" to take an
> integer location, and start_codon to take a three letter string.

I am not too worried about long arguments, so 'assert_first_codon_init' would
be fine for me (though does this mean that the first codon of the sequence
should be an initiation codon, or that translation should start from the first
initiation codon?), but I see the drive for, and value of, brevity.  If there's
a short, unambiguous option name that you can think of, I'm all for it.  An
option name that is a little cryptic, but not misleading, such as 'init', also
works for me.  I would have to go to the minor effort of typing
help(seq.translate) to find out what it meant, but it's not very much of a
chore.

Also, people learn all kinds of non-standard uses for cryptic terms, all the
time.  For example, what on earth does 'popen3' mean?  Why not
open_pipes_with_stdin_stdout_stderr?  'popen3' is short, unambiguous (if not
immediately obvious), and if you want to know what it means, then help() or a
dip in the documentation will tell you.  I think the same will be true of
'init', so long as no-one is likely to confuse it with some other meaning.

L.


-- 
Configure bugmail: http://bugzilla.open-bio.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the Biopython-dev mailing list