Differences between revisions 4 and 42 (spanning 38 versions)
Revision 4 as of 2024-12-05 14:32:45
Size: 5266
Editor: trunil
Comment:
Revision 42 as of 2024-12-12 09:03:16
Size: 2900
Editor: mark
Comment:
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:
Here, we will investigate the genome-scale metabolic model of ''P. tricornutum'' to identify pathways for TAG synthesis''. For ''''further ''''detail''''s you can ''''refer'''' ''''to Villanova V et al ''''(2021) Boosting Biomass Quantity and Quality by Improved Mixotrophic Culture of the Diatom ''''''Phaeodactylum tricornutum''''''. ''''''Front. Plant Sci.'''''' 12:642199. doi: 10.3389/fpls.2021.642199'''''''' ''' == Part 1 ==
Here, we will investigate the genome-scale metabolic model of ''P. tricornutum'' to identify pathways for TAG synthesis''. ''See'' Villanova et al (2021). Front. Plant Sci. 12:642199. doi: 10.3389/fpls.2021.642199''
Line 4: Line 5:
'''1. Download the archive containing the model and extract the files. '''  1. Download the archive containing the model from [[http://mudsharkstatic.brookes.ac.uk/Nottingham2024/P5.zip|here]] and extract the files.This will generate a new directory,"srcs", containing two sub-directories: "Model" and "Analysis". Start !ScrumPy.
 1. Load the Model:
  1. m = !ScrumPy.Model("../Model/Phaeo.spy")
 1. We can now generate a linear programming object:
  1. lp = m.GetLP()
 1. And specify minimising total flux as the objective:
  1. lp.!SetObjective(m.sm.cnames)
 1. With the constraint that we must generate 1 mole of TAG:
  1. lp.!SetFixedFlux({"TAG_Exp_tx":-1})
 1. We can now solve the lp:
  1. lp.Solve()
 1. And obtain the solution:
  1. sol = lp.!GetPrimSol()
Line 6: Line 19:
 a. '''Start ScrumPy in the folder containing the .spy files and load the top-level model file Phaeo.spy to create a model object. Note that the model is created in a modular fashion, and the top-level file will load the different components of the model and each module will be in a separate tab. '''
 a. '''Can you explain why there are more modules in this model compared to Campylobacter model? '''
Sol is a dictionary, mapping reactions to fluxes, satisfying our constraints and objectives. Examine its properties. e.g. what transport processes are involved?
Line 9: Line 21:
'''2. Set up and solve an LP problem where the objective is to minimise total flux (see previous practical), while producing 1 unit flux of TAG (Hint: use SetFixedFlux() function on reaction ‘TAG_synthesis_Cyto’). '''  . for r in sol:
Line 11: Line 23:
 a. '''What is the source of energy in your LP solution ? '''
 a. '''Examine the source of carbons. '''
 . if "_tx" in r:
  . print(r, sol[r])
Line 14: Line 26:
'''3. Now we will perform lipid scan analysis under mixotrophic condition. We will perform this analysis under various growth conditions so better to write the steps into python method, for re-usability. ''' Reaction and metabolite names are derived from [[https://metacyc.org|MetaCyc]] so you can use thses to find out more about individual reactions in the solution. NB: the `_Cyto suffix` is added to differentiate compartmentalisation in the model and is not part of !MetaCyc identifier, and should be removed before searching on !MetaCyc.
Line 16: Line 28:
'''The code that you will be using is stored in module “LipidScan.py” in the “Analysis” directory. (Note: Model directory contains the model definition files i.e .spy files and analysis contains the python modules, i.e., the ` .py` files you will need for this practical) '''  . ''' ''' <<BR>>
Line 18: Line 30:
'''The module "LipidScan.py" contains three methods. Following is their code: ''' == Part 2 - Constraint Scanning ==
Part 1 describes how to examine a single lp solution. Now we can move on to exploring multiple solutions and examine how Phaeo can rearange its metabolism in response to increasing TAG demand. The "Analysis" directory contains a simple Python module, LipidScan.py, to facilitate this.
Line 20: Line 33:
'''a. Changers method ''' Having started !ScrumPy and loaded the model as in Part 1, we import the !LipidScan module:
Line 22: Line 35:
{{{
def Changers(ds,lim=1e-06):
 rv = []
 for cname in ds.cnames:
  col = ds.GetCol(cname)
  if abs(max(col)-min(col))>lim:
   rv.append(cname)
 return rv
}}}
 . >>> import !LipidScan
Line 32: Line 37:
'''b. BuildLP method ''' (The model must be loaded first)
Line 34: Line 39:
{{{
def BuildLP(m):
 lp = m.GetLP()
 lp.SetObjective(m.sm.cnames)
 lp.SetFluxBounds({"RIBULOSE-BISPHOSPHATE-CARBOXYLASE-RXN_Plas":(0,400.0)})
 if "GLYCEROL_Cyto_tx" in m.sm.cnames:
  lp.SetFluxBounds({"GLYCEROL_Cyto_tx":(0,20)})
 return lp
}}}
'''c. LipidScan method '''
We can now generate some results:
Line 45: Line 41:
{{{
}}}
'''To use these methods you need to import the "LipidScan" module. On ScrumPy window execute the following statements. '''
 . >>> res = [[LipidScan|!LipidScan]].LipidScan(m)
Line 49: Line 43:
 . {{{#!python
import sys
sys.path.append('../Analysis')
import LipidScan
}}}
"res" is a !DataSet, (matrix-like) object that contains 100 lp solutions, for the model, subject to a varying demand for TAG and satisfyng demand for biomass precursors. We are only interested in the reactions that change:
Line 55: Line 45:
''' '''  . >>> chs = !LipidScan.Changers(res)
Line 57: Line 47:
Now the methods in the "LipidScan" module can be used. ''' ''' Commonly, we start by examining the transport processes, which can be conveniently plotted:
Line 59: Line 49:
 a. Generate LP problem where the objective is to minimise total flux. Constrain the maximum Rubisco flux and glycerol transporter flux to 400 and 20 respectively (make use of SetFluxBounds() function). ''' '''lp = LipidScan.BuildLP(m) ''' '''
 a. Solve this LP repeatedly (using for loop) while increasing flux in TAG synthesis reaction in range between 1 to 20. Save each of the solution in a dataset. Import numpy from ScrumPy.Data import DataSets
 . >>> res.!SetPlotX("TAG_Exp_tx") >>> for ch in chs:
  . if "_tx" in ch:
   . res.!AddToPlot(ch)
Line 62: Line 53:
''' ''' This more than is immediately convenient, so we can remove the plasted transporters, to leave only the cytosolic transporters:
Line 64: Line 55:
ds = LipidScan(m, lp=lp) ''' '''  . >>> res.!RemoveMatchesFromPlot("_Plas")
Line 66: Line 57:
 a. Examine the flux pattern in Rubisco reaction with respect to increasing flux in TAG synthesis. What is the maximum flux in Rubisco reaction? ds.SetPlotX("TAG_synthesis_Cyto") #setting x-axis ds.AddToPlot("RIBULOSE-BISPHOSPHATE-CARBOXYLASE-RXN_Plas") At which point an interpretable pattern starts to emerge.
Line 68: Line 59:
''' '''

 a. Add inorganic carbon transporters (Hint: “CO2_Cyto_tx” and “HCO3_Cyto_tx”) and organic carbon transporter (“GLYCEROL_Cyto_tx”) to the plot ''' '''
 a. What is the maximum flux in TAG synthesis? ''' '''

4. As you would have noticed TAG synthesis in above example is through mixotrophic mode (I.e model uses light energy and organic carbon, glycerol, for lipid production). As you remember from the lecture, ''P. tricornutum'' can grow under phototrophic condition (i.e in the absence of glycerol). As you have saved the method in ../Analysis/MyLipidScan.py. We will import the module (as shown below) and repeat the above analysis for phototropic condition. For this, constrain the flux in glycerol transporter to zero. ''' '''

lp = LipidScan.BuildLP(m) ''' '''

 . lp.SetFixedFlux({"GLYCEROL_Cyto_tx":0}) ''' '''res = MyLipidScan.LipidScan(m, lp=lp) ''' '''

 * Plot reactions as above. Examine the difference in flux patterns. ''' '''
 * What is the maximum feasible flux in TAG synthesis under phototrophic condition? ''' '''
 * Is is higher or lower than that in mixotrophic condition (in question 3)? ''' '''

5. Find the reactions that are active in mixotrophic condition but not in phototrophic condition? ''' '''

from ScrumPy.Util import Set ''' '''

 . Set.Complement(ds.cnames,res.cnames) ''' '''

Can you identify which pathways these reactions belong to? Refer to network diagram in lecture slides for convenience or visit MetaCyc. Note that `_Cyto suffix` is added to differentiate compartmentalisation in the model and is not part of MetaCyc identifier. ''' '''

https://mudsharkstatic.brookes.ac.uk/Nottingham2022/P6/ ''' '''
Over to you!

Practical 5: Identifying pathways for TAG synthesis in Phaeodactylum tricornutum

Part 1

Here, we will investigate the genome-scale metabolic model of P. tricornutum to identify pathways for TAG synthesis. See Villanova et al (2021). Front. Plant Sci. 12:642199. doi: 10.3389/fpls.2021.642199

  1. Download the archive containing the model from here and extract the files.This will generate a new directory,"srcs", containing two sub-directories: "Model" and "Analysis". Start ScrumPy.

  2. Load the Model:
    1. m = ScrumPy.Model("../Model/Phaeo.spy")

  3. We can now generate a linear programming object:
    1. lp = m.GetLP()
  4. And specify minimising total flux as the objective:
    1. lp.SetObjective(m.sm.cnames)

  5. With the constraint that we must generate 1 mole of TAG:
    1. lp.SetFixedFlux({"TAG_Exp_tx":-1})

  6. We can now solve the lp:
    1. lp.Solve()
  7. And obtain the solution:
    1. sol = lp.GetPrimSol()

Sol is a dictionary, mapping reactions to fluxes, satisfying our constraints and objectives. Examine its properties. e.g. what transport processes are involved?

  • for r in sol:
  • if "_tx" in r:
    • print(r, sol[r])

Reaction and metabolite names are derived from MetaCyc so you can use thses to find out more about individual reactions in the solution. NB: the _Cyto suffix is added to differentiate compartmentalisation in the model and is not part of MetaCyc identifier, and should be removed before searching on MetaCyc.


Part 2 - Constraint Scanning

Part 1 describes how to examine a single lp solution. Now we can move on to exploring multiple solutions and examine how Phaeo can rearange its metabolism in response to increasing TAG demand. The "Analysis" directory contains a simple Python module, LipidScan.py, to facilitate this.

Having started ScrumPy and loaded the model as in Part 1, we import the LipidScan module:

  • >>> import LipidScan

(The model must be loaded first)

We can now generate some results:

"res" is a DataSet, (matrix-like) object that contains 100 lp solutions, for the model, subject to a varying demand for TAG and satisfyng demand for biomass precursors. We are only interested in the reactions that change:

  • >>> chs = LipidScan.Changers(res)

Commonly, we start by examining the transport processes, which can be conveniently plotted:

  • >>> res.!SetPlotX("TAG_Exp_tx") >>> for ch in chs:

    • if "_tx" in ch:
      • res.AddToPlot(ch)

This more than is immediately convenient, so we can remove the plasted transporters, to leave only the cytosolic transporters:

  • >>> res.RemoveMatchesFromPlot("_Plas")

At which point an interpretable pattern starts to emerge.

Over to you!

None: Meetings/Nottingham2024/Prac5 (last edited 2024-12-12 09:03:16 by mark)