Ejemplo n.º 1
0
    def test_gene_expression(self):
        # Set up the standard TXTL tubes
        tube1 = txtl.extract('BL21_DE3')
        tube2 = txtl.buffer('stdbuffer')

        # Now set up a tube that will contain our DNA
        tube3 = txtl.newtube('geneexpr')

        # Define a DNA strand using strings (ala MATLAB)
        gene1 = txtl.assemble_dna('ptet(50)', 'BCD2(20)', 'tetR(1200)')
        txtl.add_dna(tube3, gene1, 1, 'plasmid')

        # Create individual DNA components based on standard types
        ptet = txtl.RepressedPromoter('ptet', 'tetR', dimer=True)
        bcd2 = txtl.ConstitutiveRBS('BCD2', Ribosome_Binding_F=10)
        degfp = txtl.ProteinCDS('deGFP', maturation_time=30 * txtl.minutes)
        lva = txtl.DegradationTag('lva', 'clpXP')

        # Assemble a gene using objects instead of strings
        gene2 = txtl.assemble_dna(ptet, bcd2, degfp, lva)
        txtl.add_dna(tube3, gene2, 1, 'plasmid')

        # Mix the contents of the individual tubes
        well1 = txtl.combine_tubes([tube1, tube2, tube3])

        # Create an SBML file containing the model
        txtl.write_sbml(well1, 'geneexpr.xml')
Ejemplo n.º 2
0
    def test_assemble_objects(self):
        mix = txtl.Mixture('testmix')

        ptet = txtl.RepressedPromoter('ptet', 'tetR', dimer=True)
        bcd2 = txtl.ConstitutiveRBS('BCD2', Ribosome_Binding_F=10)
        degfp = txtl.ProteinCDS('deGFP', maturation_time=30 * txtl.minutes)
        lva = txtl.DegradationTag('lva', 'clpXP')

        gene = txtl.assemble_dna(ptet, bcd2, degfp, lva)
        txtl.add_dna(mix, gene, 1, 'plasmid')
Ejemplo n.º 3
0
    def test_default_parameters(self):
        # Use default configuration information
        ptet = txtl.components.ptet()

        # Create a new component with default configuration information
        ptet = txtl.RepressedPromoter('ptet', 'tetR', dimer=True)
Ejemplo n.º 4
0
 def test_config_file(self):
     # Overwrite system configuration file with local configuration file
     ptet = txtl.RepressedPromoter('ptet', 'tetR', dimer=True,
                                   config_file='prom_ptet.csv')
     ptet = txtl.components.ptet(config_file='prom_ptet.csv')
Ejemplo n.º 5
0
# Now set up a tube that will contain our DNA
tube3 = txtl.newtube('geneexpr')

# Define a DNA strand using strings (ala MATLAB)
gene1 = txtl.assemble_dna(prom='ptet(50)', utr5='BCD2(20)', cds='tetR(1200)')
txtl.add_dna(mixture=tube3, dna=gene1, conc=1, type='plasmid')

#
# Assemble a DNA strand using objects (semi-pythonic)
#
# Note: these constructs would normally live inside of a model
# library, but this shows how to extend functionality by creating
# constructs inline.

# Create individual DNA components based on standard types
ptet = txtl.RepressedPromoter('ptet', 'tetR', dimer=True)
bcd2 = txtl.ConstitutiveRBS('BCD2', Ribosome_Binding_F=10)
degfp = txtl.ProteinCDS('deGFP', maturation_time=30 * txtl.minutes)
lva = txtl.DegradationTag('lva', 'clpXP')

# Assemble a gene using objects instead of strings
gene2 = txtl.assemble_dna(ptet, bcd2, degfp, lva)
txtl.add_dna(tube3, gene2, 1, 'plasmid')

# Mix the contents of the individual tubes
well1 = txtl.combine_tubes([tube1, tube2, tube3])

# Run a simulation
#! TODO: implement
simdata = txtl.bioscrape.runsim(well1, 8 * txtl.hours)