[Biopython-dev] Adjusting the xxMotif wrapper / Bio.Application plans
christian at brueffer.de
Thu Aug 8 10:37:19 UTC 2013
On 8/7/13 0:51 , Peter Cock wrote:
> Hi Christian et al.,
> I've just noticed something in the XXmotif wrapper which
> I should have raised back in November 2012 when it was
> committed. This is to do with the way the options were
> define, e.g.
> _Option(["--negSet", "negSet", "negset", "NEGSET"],
> "sequence set which has to be used as a reference set",
> filename = True,
> equate = False),
> The first argument is a list of names, aliases which can
> be used via the (legacy) set_parameter method. Of
> these the first is what goes in the actual command
> string, and the last must be a valid Python identifier
> and becomes a property and a keyword argument
> for the __init__ method (and ideally follow PEP8
Yeah, unfortunately I wasn't aware of this detail.
> Normally the _Option would just have TWO alias,
> in this case ["--negSeq, "negset"] would seem best.
> Clearly I'd not documented this well enough, but
> I've tried to make this more explicit now:
> Was there a special reason for all these case variants
> in the XXmotif options??
I basically followed the example set by
Bio/Align/Applications/_Clustalw.py. The "rationale" was to allow for
people to use their
favourite spelling variety.
I guess it was bad luck this happened to serve as an example, as it
was the first piece of code I ever touched in BioPython.
It would be nice to streamline all application wrappers in this regard
More information about the Biopython-dev