예제 #1
0
    def get_reaction(self):
        rxn = MasterMix(self.buffers[self.transfer_type])
        rxn.extra_percent = 20
        rxn.extra_min_volume = '1 µL'

        if isinstance(self.samples, int):
            rxn.num_reactions = self.samples
        else:
            rxn['DNA'].name = ','.join(self.samples)
            rxn.num_reactions = len(self.samples)

        if x := self.num_spots:
            rxn.num_reactions = x
예제 #2
0
def test_master_mix_scale(params):
    mm = MasterMix()
    mm.num_reactions = params['n']
    mm.solvent = 'w'
    mm.volume = params['vol_rxn']
    mm['x'].volume = params['vol_x']
    mm['w'].master_mix = True
    mm['x'].master_mix = True

    if 'fraction' in params:
        mm.extra_fraction = params['fraction']
        assert mm.extra_percent == pytest.approx(params['fraction'] * 100)
    if 'percent' in params:
        mm.extra_percent = params['percent']
        assert mm.extra_fraction == pytest.approx(params['percent'] / 100)
    if 'reactions' in params:
        mm.extra_reactions = params['reactions']
    if 'min_vol' in params:
        mm.extra_min_volume = params['min_vol']

    assert mm.get_scale() == pytest.approx(params['expected'])
예제 #3
0
import stepwise
from inform import plural
from stepwise import Protocol, Step, Footnote, MasterMix

p = Protocol()
n = 6

loading_buf = MasterMix("""\
Reagent                 Stock     Volume MM?
======================  =====  ========= ===
water                          to 5.0 µL   y
Bolt LDS sample buffer     4x     2.5 µL   y
Bolt reducing agent       10x     1.0 µL   y
""")
loading_buf.num_reactions = 2 * n
loading_buf.extra_percent = 50

protein_samples = MasterMix("""\
Reagent                        Stock      Volume MM?
=========================  =========  ========== ===
water                                 to 10.0 µL   y
loading buffer master mix         2x      5.0 µL   y
BSA                        500 ng/µL      1.0 µL   y
""")
protein_samples.num_reactions = n
protein_samples.extra_percent = 10

dna_samples = MasterMix("""\
Reagent                        Stock      Volume MM?
=========================  =========  ========== ===
예제 #4
0
{huh}

- Incubate at 37°C for 15 min.
"""

bal31 = MasterMix("""\
Reagent            Stock    Volume  MM?
================  ======  ========  ===
water                     to 50 µL  yes
dCas9-PCV2-DNA    100 nM     10 µL
NEBuffer 3.1 [2]     10x      5 µL  yes
BAL-31            1 U/µL      1 µL     
""")
bal31.hold_ratios.volume = '20 µL'
bal31.num_reactions = 3

p += f"""\
Setup {plural(bal31.num_reactions):# BAL-31 digestion/s} [1]:

{bal31}

- Incubate at 30°C for 10 min.
- Add EGTA to 30 mM
- Incubate at 65°C for 10 min.
"""

p.footnotes[1] = """\
The NEB protocol calls for 3 pmol of DNA ends.  
This reaction has 1 pmol DNA, which is 2 pmol 
ends.  Maybe I should use less BAL-31 to