-
Notifications
You must be signed in to change notification settings - Fork 0
/
examineGcOptResults.m
74 lines (56 loc) · 2.16 KB
/
examineGcOptResults.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
function ex = examineGcOptResults(results, results_wt)
% Examine gcOpt results struct for GC mutants
% Maximal growth rate
% Minimal production rate at maximal growth (Ymin)
% Ratio between pRmin and maximal theoretical production rate
% Minimal productivity at maximal growth
% Ratio between Pmin and maximal theoretical productivity
% GCS
% Growth state according to MiMBl
% if gcOpt results are invalid stop examination
if results.validity ~= 1
ex.gcs = -2;
return
end
rxnNumSubs = find(ismember(results.model.rxns,results.model.subsRxn));
rxnNumTarget = find(ismember(results.model.rxns,results.model.targetRxn));
yRange_wt = results_wt.yieldR;
pRange_wt = results_wt.prodR;
yRange_mut = results.printData.yieldR;
mRange_mut = results.printData.muR;
pRange_mut = results.printData.prodR;
%% Wild type
[th_maxY, ~] = max(yRange_wt);
[th_maxP, ~] = max(pRange_wt);
compSave = [];
%% Maximal growth rate
[ex.maxMu, ~] = max(mRange_mut);
compSave = [compSave,ex.maxMu];
%% Minimal production rate at maximal growth (minPR)
isMax = yRange_mut(mRange_mut==ex.maxMu);
ex.minPR_maxMu = min(isMax);
compSave = [compSave,ex.minPR_maxMu];
%% Ratio between PRmin and maximal theoretical production rate [%]
ex.ratio_minPR = (ex.minPR_maxMu/th_maxY)*100;
compSave = [compSave,ex.ratio_minPR];
%% Minimal productivity at maximal growth (Pmin)
isMax = pRange_mut(mRange_mut==ex.maxMu);
ex.minP_maxMu = min(isMax);
compSave = [compSave,ex.minP_maxMu];
%% Ratio between Pmin and maximal theoretical productivity [%]
ex.ratio_minP = (ex.minP_maxMu/th_maxP)*100;
compSave = [compSave,ex.ratio_minP];
%% Growth coupling strength
ex.gcs = calcGCS(results, results_wt);
compSave = [compSave,ex.gcs];
% compact structure
ex.compSave = compSave;
%% Yield at maximal growth
model = results.model;
% apply KOs
model = changeRxnBounds(model,model.rxns(results.KORxnNum(:,1)),0,'b');
% FBA
model = changeObjective(model,model.bmRxn);
sol = optimizeCbModel(model,'max','one');
ex.Y_maxMu = sol.x(rxnNumTarget)/(-sol.x(rxnNumSubs));
end