-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat/anaerobicgrowth&Nitrogen-limited growth #199
Conversation
so to not rely on added paths
* avoid initializing cobra for speed-up * linted all files * some typo fixes
to avoid undesired changes
* isolate rescalePseudoReaction * move sumBioMass & fitGAM
MW data is now loaded at the beginning of the function
* scaleBioMass is now a function for scaling any component in the biomass pseudoreaction * called by anaerobicModel.m and growth.m * old scaleBioMass is now renamed "fixBiomassComp", to avoid confusion
if lipid is chosen, 2 pseudoreactions need to be rescaled
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@feiranl after the refactoring changes I introduced I don't have any more issues, we can merge :)
-
There's a new function
scaleBioMass
which can be used for rescaling any biomass component, but without the additional changes from the old script. It also has an option for balancing out the total mass so that it adds to 1 g/gDW. The oldscaleBioMass
has been renamed tofixBiomassComp
to be more explicit about its purpose (does not break BC as the oldscaleBioMass
was not a function to begin with). -
sumBioMass
does not rely on thedata
input anymore, as it builds it from within. -
rescalePseudoReaction
has been isolated so that it can be called by its parent but also by the newscaleBioMass
. -
I noticed that predictions changed a bit, and this is I believe due to what we discussed before: For example, in the case of N-limited anaerobic conditions, with the old
scaleBioMass
it didn't matter the changes you were introducing in the nitrogen section, as they were being over-written by the original changes when callinganaerobicModel
(which calledscaleBioMass
again). See below the old code:if strcmp(mode2,'N') content = {'carbohydrate','protein','lipid backbone','RNA'}; fraction = [0.587 0.289 0.048 0.077]; model = scaleBioMass(content,fraction,model,false,false); end if mode1 == 2 model = anaerobicModel(model); end
This is now not an issue anymore, however predictions do look slightly worse:
Let me know if the code looks good on your end (especially if the biomass composition for anaerobic/N-limited/etc conditions is being properly built), or if you have any additional comments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work!
It looks good from my side. I run the code on MAC, it generate the figure perfectly. |
Main improvements in this PR:
heme
was removed as in earlier function. This time, we update the function by removingheme
,NAD
,NADP
,NADPH
andNADH
when we simulate anaerobic condition.I hereby confirm that I have:
devel
as a target branch (top left drop-down menu)