BjornFJohansson / pydna

Clone with Python! Data structures for double stranded DNA & simulation of homologous recombination, Gibson assembly, cut & paste cloning.
Other
166 stars 45 forks source link

fuse primer_design function and Amplicon class #40

Closed BjornFJohansson closed 5 years ago

BjornFJohansson commented 7 years ago

Right now there are a couple of ways to create a PCR product.

The Anneal class takes a list of primers and a template, produces a list of Amplicon class objects. This is the most flexible way, but also the most verbose.

The pcr function takes a flexible number of arguments and produces an Amplicon object (one and only one, otherwise exception).

Finally, the primer_design function designs primers for a Dseqrecord like object, and returns an Amplicon object.

It is also possible to directly create an Amplicon object by feeding it a Dseqrecord and two primers. One idea is to allow the Amplicon constructor take only a Dseqrecord like object and automatically create one or both primers for it. This would make the primer_design function redundant and it could be removed before the final 2.0 release.