Model

Scroll To Explore


Overview

Our project is to genetically engineer an engineered bacteria to solve the problem of constipation in the elderly. In order to better visualize the selection, growth, production, and elimination processes of engineered bacteria, we have established a series of models. This includes bidirectional Mendelian randomization, growth models of engineered bacteria, production models of serotonin, drug concentration elimination models, and engineered microbiota elimination models.

First, we selected engineered bacteria based on bidirectional Mendelian randomization study. Secondly, in order to explore the growth of engineered bacteria in the intestine and subsequent research, we established a growth model. Then, on the basis of the growth model, we used the data to establish a production model of serotonin to explore the effect of engineered bacteria. After the engineering bacteria perform their functions, drug elimination is necessary. Therefore, we have established a drug concentration elimination model, aiming to achieve the best elimination effect with the smallest and safest drug concentration. Based on the growth model, we established an elimination model of engineered flora to explore the change of the number of engineered flora under the action of drugs.


Host strain selection based on bidirectional Mendelian randomization studies

Background:

Host strain selection is particularly important for genetically engineered bacteria. When selecting host strains for genetically engineered bacteria, the following factors usually need to be considered: operability, i.e., selecting strains that are easy to culture, genetically manipulate and transform can improve experimental efficiency; Stability, that is, the selection of stable strains can ensure that genetically engineered bacteria do not lose inserted foreign genes during long-term culture and passage; Metabolic pathway, that is, selecting strains with appropriate metabolic pathways that can utilize the desired substrate and produce the desired product to meet the requirements of genetic engineering; Growth rate and tolerance, selecting strains that grow fast and can tolerate the required conditions (e.g., temperature, pH, antibiotics, etc.) can help improve experimental efficiency; There is already research and literature support, that is, the selection of strains that have been widely used and studied can learn from the experience and methods of predecessors and reduce the risk and technical difficulty of experiments. Therefore, E. coli, yeast, bacillus, lactic acid bacteria, and actinomycetes are often used as host strains for genetically engineered bacteria. However, when genetically engineered bacteria are used to cure diseases, in addition to the above factors, the impact of the host strain on human health must also be considered. At the same time, changes in the abundance of intestinal bacteria by diseases can also affect the colonization of genetically engineered bacteria in the intestine. In order to solve the above problems, if a large number of traditional wet experiments are carried out, although reliable conclusions and data can be obtained, a lot of time and positive costs are not practical for the project. Therefore, here, we screened the host strain using Mendelian randomized study.

Methods:

We performed a bidirectional MR analysis to assess the causal effect of the gut microbiome on the constipation phenotype and the causal effect of the constipation phenotype on the gut microbiome. The GWAS summary data for the human gut microbiome came from the largest multi-ethnic GWAS meta-analysis conducted by the MiBioGen Consortium[1]. GWAS summary data for the constipation phenotype were taken from the UK Biobank database. The MR analysis was based on the assumption that instrumental variables (IV) were closely related to exposure; IVs are not associated with confounders; IVs can only affect outcomes through exposure and no other pathways are involved. We first selected the gut microbiome as exposure and constipation as the outcome to test whether the gut microbiome prevented or contributed to the onset of constipation. In the forward MR analysis, since SNPs of the gut microbiome rarely conform to p less than 5.0×10-8, we relaxed the p-value threshold (SNPs with p less than 1.0×10-5 were selected as IVs)[2]. To explore the effect of constipation on the abundance of potential host strains after it occurs, we also performed reverse MR analysis (constipation as exposure; Enterobacteriaceae abundance as an outcome). In reverse MR analysis, SNPs with p less than 5.0×10-8 were used as IVs for constipation. For the above IVs, we excluded SNPs with linkage imbalance (r2 less than 0.001; Hereditary distance equal to 10,000 kb) and palindromic SNPs, only SNPs with minor allele frequencies (MAFs) greater than 0.01 were included[3]. The MR-Egger test was employed to identify horizontal pleiotropy[4]. We also calculated the F statistic[5] of the SNPs to assess the strength of the instrumental variable and removed SNPs with the F statistic less than 10. In addition, Cochran's Q test was used to assess heterogeneity, and if no heterogeneity was observed (Q_p value less than 0.05), a fixed-effect (FE) model of IVW was applied, and conversely, a random-effects (RE) model of IVW was applied[6]. IVW analysis was chosen as the primary method to comply with STROBE-MR guidelines, and the OR of IVW and corresponding 95% CI were reported as results of MR analysis, and the P value of the results was considered statistically significant when the P value was less than 0.05. For forward MR, we also performed further FDR correction (p-FDR) due to the need for multiple hypothesis testing. When the p-FDR produced by the IVW method was less than 0.05, the causal relationship was considered significant. To assess the robustness of the forward and reverse MR causal relationships, we used a "leave-one-out" analysis to assess the potential impact of individual SNPs on MR effects. "TwoSampleMR" is the main R package used in the study[7].

Results:

In forward MR (gut microbiome as exposure), we identified SNPs with constipation phenotypes associated with the gut microbiome, respectively, with F statistics greater than 10 for all SNPs. Adjusted IVW results after accounting for heterogeneity are shown in Fig.1. IVW analysis showed that an increase or decrease in the abundance of microflora in about 20 was associated with the occurrence of constipation. However, the above association was no longer statistically significant after FDR correction (q_Value greater than 0.05). This meant that the changes in abundance of the above flora are weakly associated with the risk of constipation. Among the many host strains, we preferred to use E. coli as the chassis for genetically engineered bacteria because it is a mature expression vector for DH5α recombinant protein. As mentioned earlier, the Enterobacteriaceae family and the species it contains were not associated with the development of constipation, which meant that our use of E. coli as a host strain does not aggravate the symptoms of constipation in patients. However, whether symptoms of constipation affect the abundance of E. coli bacteria in the gut was still a question related to the role of genetically engineered bacteria. Therefore, in reverse MR (constipation as exposure), we used IVW, MR-Egger, WM and other methods to analyze the causal effects of constipation and Enterobacter abundance. Based on the results of IVW and WM analysis (Fig.2 and 3), it was suggested that constipation is associated with increased abundance of Enterobacteriaceae. In addition, the "leave-one-out" analysis showed that excluding any single SNP did not significantly change the overall results for both associations (Fig.4). These results showed that in the case of constipation, the abundance of Enterobacteriaceae in patients would increase, which was conducive to the colonization and function of genetically engineered bacteria based on Escherichia coli.

Gut-sweeper
Fig. 1 | Forest plot of MR results of gut microbiome against constipation phenotypes

Gut-sweeper
Fig. 2 | Forest plot of MR results of constipation phenotypes against gut abundance of Enterobacteriaceae

Gut-sweeper
Fig. 3 | Visualization of MR results of constipation phenotypes against gut abundance of Enterobacteriaceae

Gut-sweeper
Fig. 4 | Model robustness of "leave-one-method" analysis for constipation phenotypes against gut abundance of Enterobacteriaceae

Mathematical modeling of E. coli growth

Background:

The study of the number of E. coli flora in the intestine has always been a very important and fundamental topic, because it is related to the production and safety measures of subsequent products. So in such a complex environment as the intestine, how to establish a suitable model to simulate the number of flora, we found that we can first start from a single flora growth model in the culture medium, and then simulate the growth of E. coli in the intestine. The Malthus model is an exponential growth model in which the natural growth rate of bacteria remains constant without taking into account any environmental factors and external conditions. However, whether in the medium or in the intestine, the amount of environmental volume is limited, so the growth is limited, and the environmental resistance is positively correlated with the number of flora, so we need to correct the natural growth rate of the parameter. Overall, we corrected the necessary parameters to fit the experimental data well.

Methods:

Mathematical expression of E. coli growth model:

Gut-sweeper
Gut-sweeper
Tab.1 | Description of E. coli growth parameters

Without considering any environmental factors and external conditions, the natural growth rate of bacteria remains unchanged, let N be the number of flora at a certain time, N0 is the number of initial flora, t is the time, and the natural growth rate of bacteria is r, then the instantaneous growth rate of the population is dN/dt, so as to establish a model:

Gut-sweeper

Combining the two equations yields:

Gut-sweeper

This is the Malthus model, but the environmental capacity in the medium is limited and the environmental resistance is positively correlated with the number of flora, so we set the maximum number of flora to Nm and correct the natural growth rate r

Gut-sweeper

Since environmental resistance is positively correlated with the number of flora, the natural growth rate r is negatively correlated with the number of flora[8] Based on the simple conditions in the medium, we hypothesize:

Gut-sweeper

r0 is a fixed growth rate, α is a parameter, when N reaches the maximum number of flora, r(Nm) = 0, there is α = r0/Nm, which can eventually be corrected to:

Gut-sweeper

Combining the two equations yields:

Gut-sweeper

This is the E. coli growth model in the medium[9].

Assumptions:

1.The growth rate r of E. coli in culture medium does not change with factors other than the number of flora[10].

2.Except for the limitation of the volume of the growing environment, the remaining factors are suitable and sufficient.

Results:

The acquisition of experimental data is critical to fitting the results, so in order to obtain sufficient and continuous experimental values, we draw on the methods in the literature[11]. The specific steps are as follows:

1.Inoculate a single colony of E. coli strain into 5 ml LB medium in a culture tube for overnight culture.

2.Overnight liquid bacterial cultures are diluted 500-50-fold at 100 μg/ml in fresh LB medium.

3.Pipette 200 μl of the diluted culture into a single well of a 96-well plate, preparing three copies of the sample each.

4.Prepare blank medium for the same conditions to pipette into three wells of a 96-well plate.

5.After loading all samples and blank controls, use a microplate reader and Gen5 software to acquire growth curve experimental data at a sampling frequency of 10 min intervals at each interval.

6.The original data acquisition and processing methods are shown in Appendix S1, and the results are shown in Fig.5.

Gut-sweeper
Gut-sweeper
Fig. 5 | Raw data on E. coli growth curves (left: growth curve; right: first derivative of growth curve)

It can be seen from the standard curve experiment that 1OD600nm is about, so it is easy to convert the measured E. coli optical density growth curve into E. coli concentration growth curve. Using a Python program 108 CFU·ml-1(see Appendix S2), the image result of the fitted curve (see Fig.6) and the calculated values of the fitted parameters can be obtained, where , r0 = 0.25 hr-1, Nm = 0.80 CFU·ml.

Gut-sweeper
Fig. 6 | Fitting results of E. coli growth curves

Mathematical modeling of Product production

Background:

The formation process of serotonin is that tryptophan is catalyzed by tryptophan carboxylase[12,13], first generating 5-hydroxytryptopha, and then catalyzed by serotonin decarboxylase to serotonin[14], among which there are also many processes of biological enzymatic transformation. The production of products in this model is related to the number of bacterial flora, so the production model is closely related to the growth model. A series of enzymatic reactions for tryptophan production is reduced to a first-order chemical reaction, i.e. a reaction whose reaction speed is only proportional to one square of reactant concentrations. Here, we transform several product generation processes into one total process without considering the small processes of individual enzyme transformations, thus establishing reaction mechanisms to describe the production and consumption of chemicals, allowing us to predict how serotonin production changes over time. In summary, we simplified the serotonin production process, focusing only on the main product serotonin, and successfully predicted the E. coli production curve.

Methods:

Product production model mathematical expression:

Gut-sweeper
Gut-sweeper
Tab.2 | Meaning of E. coli production parameters

Set E the product yield of a single bacterium per unit time, that is, the natural expression rate, y is the product yield at a certain time, y0 is the initial product yield, t is the time, and N is the number of bacterial flora, then the instantaneous product yield rate of the flora is dy/dt , so as to establish a model:

Gut-sweeper

The expression of the number of substitute E. coli growth numbers is:

Gut-sweeper

Combining the two equations yields:

Gut-sweeper

This is the model of E. coli product production in culture media.

Assumptions:

1.The series of enzymatic reactions of serotonin is negligible and is considered a total reaction process[15].

2.The natural expression rate of E. coli production of serotonin does not vary with other factors.

Results:

In order to facilitate to get the experimental results, we replaced the 1:1 part of the original expression of TPH1 and TDC1 with EGFP (see Fig.7), which has the advantage of reacting the expression of TPH1 and TDC1 by fluorescence intensity. However, since the expression of TPH1 and TDC1 has a nonlinear relationship with the production of serotonin, the fluorescence intensity can only indirectly reflect the production of serotonin, that is, the ability to produce E. coli products. The specific steps are as follows:

Gut-sweeper
Fig.7 | Schematic diagram of genes for product production model experiments

1.Inoculate a single colony of E. coli strain into 5 ml LB medium in a culture tube for overnight culture.

2.Overnight liquid bacterial cultures were added to fresh LB medium containing 0 mM sodium butyrate and 20 mM sodium butyrate, respectively, and diluted 500-50 times at 100 μg/ml.

3.Pipette 200 μl of the diluted culture into a single well of a 96-well plate and prepare three copies of the sample for a total of six.

4.Prepare blank medium under the same conditions and pipette into three wells of a 96-well plate.

5.After loading all samples and blank controls, use a microplate reader and Gen5 software to collect the fluorescence intensity experimental data of the product production model at a sampling frequency of 10 min at intervals of 10 minutes each time.

6.The original data acquisition and processing method is shown in Appendix S1, and the results are shown in Figure 4. Since EGFP expression was detected in E. coli in 0 mM sodium butyrate medium, only experimental data from the product production model of E. coli in 20 mM sodium butyrate medium are presented here.

Gut-sweeper
Gut-sweeper
Fig.8 | Raw data on E. coli product production (left: production curve; right: first derivative of production curve)

Using a Python program (see Appendix S3), the image result of the fitted curve (see Fig.9) and the calculated value of the fitted parameters, i.e., E = 786.81 a.u.·ml·108CFU-1·hr-1.

Gut-sweeper
Fig.9 | Fitting results of E. coli product curves

About the kinetic model of drug elimination of enteral tetracycline

Background:

Tetracycline has been widely used in various medical applications. Most of the tetracycline is absorbed into the blood in the intestine, so the study of the drug elimination kinetics of tetracycline in the intestine has always been a very important and basic topic, based on the research of this topic, the appropriate dose interval of tetracycline can be obtained, so as to serve the overall topic. So how to establish a suitable model to simulate drug concentrations in complex intestinal environments, and the use of first-order and zero-order elimination kinetic models alone does not fit the intestinal tetracycline elimination trend well in the case of high and low drug concentrations. Finally, we found that it was possible to integrate first-order and zero-order elimination kinetic models to simulate intestinal tetracycline drug concentrations using a mixed elimination kinetic model (i.e., zero-order kinetic elimination at high concentrations and first-order kinetic elimination at low concentrations)[16,17].

In general, the mixed elimination kinetics model can be expressed by the Michaelis-Menten kinetic equation, which is a model that can better fit intestinal tetracycline elimination after considering the kinetics of first-order and zero-order elimination.

Methods:

Ⅰ.Establishment of tetracycline elimination model after single intestinal administration

Gut-sweeper
Gut-sweeper
Tab.3 | Description of intestinal drug elimination parameters

Michaelis-Menten kinetic equation:

Gut-sweeper

Without considering other environmental factors, the drug in the intestine is eliminated according to the Michaelis-Menten kinetic equation, then we set the initial drug concentration to integrate the Michaelis-Menten kinetic equation as: C0

Gut-sweeper

Combining the above two equations yields:

Gut-sweeper

In general, we refer to the time it takes for a drug concentration to be eliminated to half as the half-life, and the half-life does not change due to changes in the drug concentration[18], so the measurement of half-life in the experiment will be relatively easy, and we can replace the maximum elimination rate Vm with half-life t1/2

Gut-sweeper

Combining the above two equations yields:

Gut-sweeper

Substituting the equation Kmln(C/C0) + CC0 + Vmt = 0 is:

Gut-sweeper

This is the model of elimination of drug concentrations in the intestine after a single administration of tetracycline.(See Fig.10)

II. Establishment of tetracycline elimination model after multiple intestinal administrations

In order to ensure that the tetracycline concentration in the intestine is balanced, we cannot just give the drug once, so we need multiple doses (the interval between doses is half-life), and the elimination law of multiple doses still follows the intestinal drug elimination model after a single dose, but the drug concentration will change after each dose, so multiple function iterations are required[19].(See Fig.11)

Assumptions:

1.The half-life of tetracycline does not change due to changes in the intestinal environment and drug concentrations.

2.The Michaelis-Menten constant is the drug concentration at a maximum elimination rate of 50% and does not change with the change of drug concentration.

3.The tetracycline concentration is the same for each dose, the interval between each dose is the same (the half-life)[20].

Results:

Please refer to the appendix (Python script) for the detailed process (see Appendix S4 and S5).

Gut-sweeper
Fig.10 | Model of tetracycline elimination after a single administration in the intestine[21]
Gut-sweeper
Fig.11 | Model of tetracycline elimination after multiple enteral administration

Establishment of a model of intestinal flora elimination

Background:

Based on the above studies of growth model and drug concentration model, we obtained the growth curve of the microbiota and the stable drug concentration curve. After the engineered bacteria complete the task of expressing serotonin and relieve the symptoms of constipation, for safety reasons, we need to apoptosis the intestinal flora to prevent the genetic mutation of engineered bacteria or the side effects of overexpression of serotonin. We start from the growth model and simulate the number of engineered bacteria eliminated by setting the proportion parameters.

Therefore, we add drugs at a certain time when the engineering bacteria grow, so that the engineered bacteria lead to apoptosis due to the participation of the drug, and finally all the engineering bacteria in the intestine are apoptosis to achieve the effect of sterilization. Therefore, we need to set a parameter to represent the elimination rate of engineered bacteria, here we set an elimination rate that varies according to the concentration of bacteria, based on the growth model, we get the elimination model of engineered bacteria.

Methods:

Mathematical expression of the intestinal flora elimination model:

Gut-sweeper
Gut-sweeper
Tab.4 | Description of engineering bacteria elimination parameters
Gut-sweeper

This is the previously obtained model of engineered bacterial growth, and next, we add a drug factor (tetracycline) to establish a model of the elimination of engineered bacteria.

We assume that R is the elimination rate of the drug on engineered bacteria and N1 is the number of engineered bacteria at the moment the drug is added, then the growth model based on it has:

Gut-sweeper

This is the elimination model of engineering bacteria.

Assumptions:

1.The growth rate r of E. coli in culture medium does not change with factors other than the number of flora.

2.Except for the limitation of the volume of the growing environment, the remaining factors are suitable and sufficient.

3.The elimination rate of engineered bacteria varies with the change of drug concentration, and the elimination rate R is greater than the growth rate r0 (1-N/Nm), so that the change rate of engineered bacteria is negative.

Results:

When we conducted the experiment, we encountered two difficulties, which we finally solved through consultation and cooperation with the experimental group:

1.When we obtained the experimental data, we found that the experimental group did not have data on tetracycline-related elimination engineering bacteria, so we negotiated and decided to use malic acid instead of tetracycline. Due to the limitation of experimental equipment, it is difficult to obtain experimental data. In the end, the members of the experimental group overcame the difficulties, worked tirelessly, and worked overtime to obtain the data of the relevant elimination engineering bacteria of malic acid.(See Fig.12)

2.When we built the model, we tried to integrate the differential expression of the model we built, but found that the integral formula was very complicated, so we used the first derivative fitting. Finally, we obtained the fitting result R=1.93 hr-1 (we used the 25nM malic acid elimination curve when fitting. See Fig.13 and see Appendix S6 for code).

Gut-sweeper
Fig.12 | Elimination curve
Gut-sweeper
Fig.13 | First derivative fitting result of elimination curve

In summary, in order to establish the elimination model of engineered bacteria in the intestine, we first establish a simple growth model, and then based on the growth model, add a parameter to simulate the elimination of engineered bacteria after adding drugs, and finally obtain the elimination model of engineered bacteria, so that the drug can eliminate all engineered bacteria in a short time.

S1: Experimental data collection

                            # 引用库+定义函数
import matplotlib.pyplot as plt  
import matplotlib as mpl  
mpl.rcParams['font.size'] = 20  
import numpy as np  
import pandas as pd  
from scipy.integrate import odeint  
from scipy.optimize import curve_fit  
from scipy.signal import find_peaks, peak_widths  
def ave(data):  
   return data.mean(axis=1)  
def std(data):  
   return data.std(axis=1)  
def sem(data):  
   return data.std(axis=1)/np.sqrt(data.shape[-1])  
def calc_stats(sample_fn, blank_fn, dt=10.0/60.0, convfac=1):  
   blank = np.loadtxt(blank_fn)  
   sample = np.loadtxt(sample_fn)  
   if blank.shape[0] == sample.shape[0]:  
       t = np.arange(0, blank.shape[0])*dt  
       sample_ave = (ave(sample) - ave(blank))*convfac  
       sample_err = np.sqrt(sem(sample)**2+sem(blank)**2)  
       return (t, sample_ave, sample_err)  
   else:  
       print('Error: blank and sample do not have the same number of data/time points')  
       return None  
def remove_baseline_from_data(sample_fn, blank_fn):  
   blank = np.loadtxt(blank_fn)  
   sample = np.loadtxt(sample_fn)  
   new_sample_data = np.zeros_like(sample)  
   baseline = ave(blank)  
   if blank.shape[0] == sample.shape[0]:  
       for col in range(sample.shape[-1]):  
           new_sample_data[:,col] = sample[:,col] - baseline  
       return new_sample_data  
   else:  
       print('Error: blank and sample do not have the same number of data/time points')  
       return None  
def smooth(x,window_len=11,window='hanning'):  
   if window_len<3:  
       return x  
   ss=np.r_[x[window_len-1:0:-1],x,x[-2:-window_len-1:-1]]  
   if window == 'flat': #moving average  
       w=np.ones(window_len,'d')  
   else:  
       w=eval('np.'+window+'(window_len)')  
   y=np.convolve(w/w.sum(),ss,mode='valid')  
   return y  
def calc_deriv(t, ys, deriv_order=1, sw=11):  
   dt = t[1]-t[0]  
   dys = []  
   for y in ys:  
       if deriv_order == 1:  
           dys.append(np.diff(smooth(y, sw))/dt)  
       elif deriv_order==2:  
           dys.append(np.diff(smooth(np.diff(smooth(y, sw))/dt, sw))/dt)  
       else:  
           print('Higher order derivatives are not supported')  
           dys.append(np.diff(smooth(y, sw))/dt)  
   dys = np.array(dys)  
   return (t, dys.mean(axis=0)[:len(t)], dys.std(axis=0)[:len(t)]/np.sqrt(len(ys)))  
def get_peak_info(t, y):  
   res = []  
   peaks, _ = find_peaks(y, height=np.max(y)/2.0)  
   for p in peaks:  
       res.append([t[p], y[p]])  
   return np.array(res)  
plt.rcParams['font.sans-serif'] = ['SimHei']  # 用来正常显示中文  
plt.rcParams['axes.unicode_minus'] = False    # 用来正常显示负号  
  
#样品od值提取  
plt.figure(figsize=(5,4))  
t1, s1, e1 = calc_stats('s1_od.txt', 'blank_od.txt')  
plt.errorbar(t1, s1, e1, fmt='o-',capsize=0.4, ms=1.2, mew=0.2,  
            elinewidth=0.2, color='tab:blue', mfc='none', label='大肠杆菌')  
plt.xlabel('时间 (hr)')  
plt.ylabel('光密度 (a.u.)')  
plt.legend()  
plt.tight_layout()  
plt.savefig('./od值.pdf')  
#od值的一阶导数  
t,s,e = calc_stats('s1_od.txt', 'blank_od.txt')  
sample = remove_baseline_from_data('s1_od.txt', 'blank_od.txt')  
ys = [sample[:,col] for col in range(sample.shape[-1])]  
t1, d1, e1 = calc_deriv(t, ys, deriv_order=1, sw=11)  
p1 = get_peak_info(t1, d1)[0]  
scfac = 1  
plt.figure(figsize=(5,4))  
plt.errorbar(t1, d1/scfac, e1/scfac, fmt='o-',ms=1.2, mew=0.2, capsize=0.4,  
            elinewidth=0.2, color='tab:blue', mfc='none',label='大肠杆菌')  
plt.xlabel('时间 (hr)')  
plt.ylabel('d光密度/dt (a.u.)')  
ylim = plt.ylim()  
plt.plot([p1[0],p1[0]],ylim, '--', color='green', zorder=99)  
plt.ylim(ylim)  
plt.legend()  
plt.tight_layout()  
plt.savefig('./od值一阶导数.pdf')  
  
#样品fl值提取  
plt.figure(figsize=(5,4))  
scfac = 1e5  
t1, s1, e1 = calc_stats('s1_fl.txt', 'blank_fl.txt')  
plt.errorbar(t1, s1/scfac, e1/scfac, fmt='o-',ms=1.2, mew=0.2, capsize=0.4,  
            elinewidth=0.2, color='tab:red', mfc='none',label='大肠杆菌EGFP')  
plt.xlabel('时间 (hr)')  
plt.ylabel('荧光强度 (*10^5a.u.)')  
plt.legend()  
plt.tight_layout()  
plt.savefig('./fl值.pdf')  
#fl值的一阶导数  
t,s,e = calc_stats('s1_fl.txt', 'blank_fl.txt')  
sample = remove_baseline_from_data('s1_fl.txt', 'blank_fl.txt')  
ys = [sample[:,col] for col in range(sample.shape[-1])]  
t1, d1, e1 = calc_deriv(t, ys, deriv_order=2, sw=11)  
p1 = get_peak_info(t1, d1)[0]  
scfac = 1e5  
plt.figure(figsize=(5,4))  
plt.errorbar(t1, d1/scfac, e1/scfac, fmt='o-',ms=1.2, mew=0.2, capsize=0.4,  
            elinewidth=0.2, color='tab:blue', mfc='none',label='大肠杆菌EGFP')  
plt.xlabel('时间 (hr)')  
plt.ylabel('d荧光强度/dt (*10^5a.u.)')  
ylim = plt.ylim()  
plt.plot([p1[0],p1[0]],ylim, '--', color='black', zorder=99)  
plt.ylim(ylim)  
plt.legend()  
plt.tight_layout()  
plt.savefig('./fl的一阶导数.pdf') 
                    
                            
                        

S2: Fitting of an E. coli growth model

                            #引用库  
import numpy as np  
import pandas as pd  
import matplotlib.pyplot as plt  
from scipy import optimize as op  
import math  
plt.rcParams['font.sans-serif'] = ['SimHei']  # 用来正常显示中文  
plt.rcParams['axes.unicode_minus'] = False    # 用来正常显示负号  
  
# 需要拟合的函数  
def function(x, R0, Nm):  
    return Nm/(1+2.5*Nm*float(math.e)**(-R0*x)-float(math.e)**(-R0*x))  
  
# 需要拟合的数据组  
x_group = np.arange(0, 171/6, 1/6)  
y_group = np.loadtxt('mean_od.txt')  
  
# 得到返回的参数值  
R0, Nm = op.curve_fit(function, x_group, y_group)[0]  
print(R0, Nm)  
  
# 拟合曲线与实验值进行比较  
x = x_group  
y = Nm/(1+2.5*Nm*float(math.e)**(-R0*x)-float(math.e)**(-R0*x))  
plt.scatter(x_group, y_group, marker='o',label='实验值')  
plt.plot(x, y,color='red',label='拟合曲线')  
plt.xlabel('时间(hr)')  
plt.ylabel('菌群浓度(10^8 CFU/ml)')  
plt.legend()   
plt.show() 

                            
                        

S3: Fitting of the product production model

                                    #引用库  
import numpy as np  
import pandas as pd  
import matplotlib.pyplot as plt  
from scipy import optimize as op  
import math  
plt.rcParams['font.sans-serif'] = ['SimHei']  # 用来正常显示中文  
plt.rcParams['axes.unicode_minus'] = False    # 用来正常显示负号  
  
# 需要拟合的函数  
def function(x, R0, Nm):  
    return Nm/(1+2.5*Nm*float(math.e)**(-R0*x)-float(math.e)**(-R0*x))  
  
# 需要拟合的数据组  
x_group = np.arange(0, 171/6, 1/6)  
y_group = np.loadtxt('mean_od.txt')  
  
# 得到返回的参数值  
R0, Nm = op.curve_fit(function, x_group, y_group)[0]  
print(R0, Nm)  
  
# 拟合曲线与实验值进行比较  
x = x_group  
y = Nm/(1+2.5*Nm*float(math.e)**(-R0*x)-float(math.e)**(-R0*x))  
plt.scatter(x_group, y_group, marker='o',label='实验值')  
plt.plot(x, y,color='red',label='拟合曲线')  
plt.xlabel('时间(hr)')  
plt.ylabel('菌群浓度(10^8 CFU/ml)')  
plt.legend()   
plt.show()

                                    
                                

S4: Single dose gut drug concentration model

                                            import math  
import numpy as np  
import matplotlib.pyplot as plt  
import math  
# 定义隐函数  
def f(x, y):  
    return np.log(y*math.e**(y/1460000000))+(1/8.5)*(250/1460000000+np.log(2))*x-np.log(500)-500/1460000000  
# 生成隐函数图像数据  
x = np.linspace(0, 100, 1001)  
y = np.linspace(0, 500, 1001)  
X, Y = np.meshgrid(x, y)  
Z = f(X, Y)  
# 绘图  
fig, ax = plt.subplots(figsize=(8, 8))  
ax.contour(X, Y, Z, levels=[0], colors=('red',), linewidths=1.5)  
##plt.title(loc='center',label='Figure1:Model of tetracycline elimination after a single administration in the intestine',font='Microsoft YaHei',fontsize='10')  
plt.xlabel('Time(hr)',loc='center',font='Microsoft YaHei',fontsize='20')  
plt.ylabel('Intestinal drug concentration(ng/mL)',loc='center',font='Microsoft YaHei',fontsize='20')  
fig.savefig(r'C:\Users\Lenovo\Desktop\文献\文章\单次给药后药物浓度.pdf')
                                            
                                        

S5: Multiple administration of intestinal drug concentration model

                                                    import numpy as np  
import matplotlib.pyplot as plt  
import math  
from scipy import optimize  
x=np.linspace(0,51,100)  
y=np.linspace(0,1000,100)  
k=1460000000  
a=math.e**(np.log(3500)+875/k)  
def f4(t):  
 return np.array(1460000000*np.log(937.5)+937.5+3*t/2+1460000000*np.log(8)-1460000000*np.log(t))  
t = optimize.fsolve(f4, [2, 6])  
p = t[1]  
c1=968.75  
t1=4  
def f4(b):  
 return np.array(k*np.log(c1)+c1+t1*(b/2+k*np.log(2))-k*np.log(b)-b)  
b = optimize.fsolve(f4, [2, 6])  
m = b[1]  
c2=984.375  
t2=5  
def f4(d):  
 return np.array(k*np.log(c2)+c2+t2*(d/2+k*np.log(2))-k*np.log(d)-d)  
e = optimize.fsolve(f4, [2, 6])  
n = e[1]  
def f(x,y):  
    if 0<=x and x<8.5:  
        return np.log(y*math.e**(y/1460000000))+(1/8.5)*(250/1460000000+np.log(2))*x-np.log(500)-500/1460000000  
    if 8.5<=x and x<17:  
        return np.log((y)*math.e**((y)/1460000000))+(1/8.5)*(750/1460000000+np.log(2))*x-np.log(1500)-1500/1460000000  
    if 17<=x and x<25.5:  
        return np.log((y)*math.e**((y)/1460000000))+(1/8.5)*(a/2/1460000000+np.log(2))*x-np.log(a)-a/1460000000  
    if 25.5<=x and x<34:  
        return np.log((y)*math.e**((y)/1460000000))+(1/8.5)*(p/2/1460000000+np.log(2))*x-np.log(p)-p/1460000000  
    if 34<=x and x<42.5:  
        return np.log((y)*math.e**((y)/1460000000))+(1/8.5)*(m/2/1460000000+np.log(2))*x-np.log(m)-m/1460000000  
    if 42.5<=x and x<51:  
        return np.log((y)*math.e**((y)/1460000000))+(1/8.5)*(n/2/1460000000+np.log(2))*x-np.log(n)-n/1460000000  
    else:  
        return 0  
f_vectorized = np.vectorize(f)  
X, Y = np.meshgrid(x, y)  
Z = f_vectorized(X, Y)  
fig, ax = plt.subplots(figsize=(8, 8))  
ax.contour(X, Y, Z, levels=[0], colors=('red',), linewidths=1.5)  
plt.xlabel('Time(hr)',loc='center',font='Microsoft YaHei',fontsize='20')  
plt.ylabel('Intestinal drug concentration(ng/mL)',loc='center',font='Microsoft YaHei',fontsize='20')  
##plt.grid()  
plt.show()  
fig.savefig(r'C:\Users\Lenovo\Desktop\文献\文章\多次给药后药物浓度.pdf')  
                                                    
                                                

S6:Establishment of a model of intestinal flora elimination

                                                          #引用库  
import numpy as np  
import pandas as pd  
import matplotlib.pyplot as plt  
from scipy import optimize as op  
import math  
plt.rcParams['font.sans-serif'] = ['SimHei']  # 用来正常显示中文  
plt.rcParams['axes.unicode_minus'] = False    # 用来正常显示负号  
  
#计算实验数据一阶导数  
x_group = [0,2,4,6,8,10,12]  
y_group = [120800,17360,1415.333333,496.6666667,184,119.6666667,72.33333333]  
  
# 计算横向间隔  
h = int(x_group[1] - x_group[0])  
  
# 计算一阶导数  
dy = np.gradient(y_group, h)  
print(dy)  
#拟合函数  
def function(y, r0, Nm, R):  
    return r0*(1-y/Nm)*y-R*y  
r0, Nm, R = op.curve_fit(function, y_group, dy)[0]  
print(r0, Nm, R)  
  
# 拟合曲线与实验值进行比较  
y = []  
for i in range(0,7):  
    y.append(r0*(1-float(y_group[i])/Nm)*float(y_group[i])-R*float(y_group[i]))  
  
#绘图  
plt.scatter(y_group, dy, marker='o',label='Experimental Value', color='orange')  
plt.plot(y_group, y,color='purple',label='Fitted Curve')  
plt.grid(True, linewidth=0.5)  
plt.xlabel('Flora Concentration(cfu/ml)')  
plt.ylabel('d(Flora Concentration)')  
plt.tick_params(axis='x', labelsize=10)  
plt.tick_params(axis='y', labelsize=10)  
plt.grid(True, linewidth=0.5)  
plt.rcParams.update({'font.size': 10})  
plt.legend()   
plt.savefig('./涂板拟合.pdf')  

                                                          
                                                      
  1. Kurilshikov A, Medina-Gomez C, Bacigalupe R, Radjabzadeh D, Wang J, Demirkan A, et al.. Large-Scale association analyses identify host factors influencing human gut microbiome composition. Nat Genet (2021) 53(2):156–65. doi:10.1038/s41588-020-00763-1
  2. Li P, Wang H, Guo L, Gou X, Chen G, Lin D, et al.. Association between gut microbiota and preeclampsia-eclampsia: a two-sample mendelian randomization study. BMC Med (2022) 20(1):443. doi: 10.1186/s12916-022-02657-x
  3. Burgess S, Butterworth A, Thompson SG. Mendelian randomization analysis with multiple genetic variants using summarized data. Genet Epidemiol (2013) 37(7):658–65. doi:10.1002/gepi.21758
  4. Rees JMB, Wood AM, Burgess S. Extending the MR-egger method for multivariable mendelian randomization to correct for both measured and unmeasured pleiotropy. Stat Med (2017) 36(29):4705–18. doi:10.1002/sim.7492
  5. Pierce BL, Ahsan H, Vanderweele TJ. Power and instrument strength requirements for mendelian randomization studies using multiple genetic variants. Int J Epidemiol (2011) 40(3):740–52. doi:10.1093/ije/dyq151
  6. Emdin CA, Khera AV, Kathiresan S. Mendelian Randomization. JAMA. 2017;318(19):1925-1926. doi:10.1001/jama.2017.17219
  7. Hemani G, Zheng J, Elsworth B, Wade KH, Haberland V, Baird D, et al.. The MR-base platform supports systematic causal inference across the human phenome. Elife (2018) 7. doi:10.7554/eLife.34408
  8. Fujikawa H, Munakata K, Sakha MZ. Development of a competition model for microbial growth in mixed culture. Biocontrol Sci. 2014;19(2):61-71. doi:10.4265/bio.19.61
  9. Xiao Y, Angulo MT, Friedman J, Waldor MK, Weiss ST, Liu YY. Mapping the ecological networks of microbial communities. Nat Commun. 2017;8(1):2042. Published 2017 Dec 11. doi:10.1038/s41467-017-02090-2
  10. Gause, G. F. (1932). Experimental Studies on the Struggle for Existence : I. Mixed population of Two Species of Yeast. Journal of Experimental Biology, 9(4), 389–402. doi: 10.1242/jeb.9.4.389
  11. Rogers, A. T., Bullard, K. R., Dod, A. C., & Wang, Y. (2022). Bacterial Growth Curve Measurements with a Multimode Microplate Reader. Bio-protocol, 12(9), e4410. https://doi.org/10.21769/BioProtoc.4410
  12. Carkaci-Salli N, Salli U, Tekin I, et al. Functional characterization of the S41Y (C2755A) polymorphism of tryptophan hydroxylase 2. J Neurochem. 2014;130(6):748-758. doi:10.1111/jnc.12779
  13. Carkaci-Salli N, Flanagan JM, Martz MK, et al. Functional domains of human tryptophan hydroxylase 2 (hTPH2). J Biol Chem. 2006;281(38):28105-28112. doi:10.1074/jbc.M602817200
  14. Yang XJ, Kaufman S. High-level expression and deletion mutagenesis of human tryptophan hydroxylase. Proc Natl Acad Sci U S A. 1994;91(14):6659-6663. doi:10.1073/pnas.91.14.6659
  15. Horton RA, Randall LP, Bailey-Horne V, et al. Degradation of cefquinome in spiked milk as a model for bioremediation of dairy farm waste milk containing cephalosporin residues. J Appl Microbiol. 2015;118(4):901-910. doi:10.1111/jam.12765
  16. Ziółkowski H, Jasiecka-Mikołajczyk A, Madej-Śmiechowska H, Janiuk J, Zygmuntowicz A, Dąbrowski M. Comparative pharmacokinetics of chlortetracycline, tetracycline, minocycline, and tigecycline in broiler chickens. Poult Sci. 2020;99(10):4750-4757. doi:10.1016/j.psj.2020.06.038
  17. Ahmad A, Græsbøll K, Christiansen LE, Toft N, Matthews L, Nielsen SS. Pharmacokinetic-pharmacodynamic model to evaluate intramuscular tetracycline treatment protocols to prevent antimicrobial resistance in pigs. Antimicrob Agents Chemother. 2015;59(3):1634-1642. doi:10.1128/AAC.03919-14
  18. Xie Y, Liu C, Huang H, et al. Bone-targeted delivery of simvastatin-loaded PEG-PLGA micelles conjugated with tetracycline for osteoporosis treatment. Drug Deliv Transl Res. 2018;8(5):1090-1102. doi:10.1007/s13346-018-0561-1
  19. Ohnishi M, Hitoshi K, Katoh M, et al. Effect of a Kampo preparation, byakkokaninjinto, on pharmacokinetics of ciprofloxacin and tetracycline. Biol Pharm Bull. 2009;32(6):1080-1084. doi:10.1248/bpb.32.1080
  20. Wu Y, Ding L, Huang NY, Wen AD, Liu B, Li WB. Pharmacokinetics of metronidazole, tetracycline and bismuth in healthy volunteers after oral administration of compound tablets containing a combination of metronidazole, tetracycline hydrochloride and bismuth oxide. Drug Res (Stuttg). 2015;65(2):74-81. doi:10.1055/s-0034-1372611
  21. Gardner TS, Cantor CR, Collins JJ. Construction of a genetic toggle switch in Escherichia coli. Nature. 2000;403(6767):339-342. doi:10.1038/35002131