-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathexample_8_LoadingandFittingData_DataLoading.m
More file actions
73 lines (56 loc) · 2.74 KB
/
example_8_LoadingandFittingData_DataLoading.m
File metadata and controls
73 lines (56 loc) · 2.74 KB
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
%% SSIT/Examples/example_8_LoadingandFittingData_DataLoading
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Section 2.3: Loading and fitting Hog1-MAPK pathway STL1 yeast data
% * Data loading and handling
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Preliminaries
% Use the STL1 model from example_1_CreateSSITModels and
% example_4_SolveSSITModels_FSP
% clear
% close all
% example_1_CreateSSITModels
% example_4_SolveSSITModels_FSP
%% Load pre-computed FSP solutions:
% load('example_4_SolveSSITModels_FSP.mat')
% View model summaries:
Model_FSP.summarizeModel
STL1_FSP.summarizeModel
STL1_4state_FSP.summarizeModel
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Load Hog1-MAPK pathway STL1 yeast data and filter by experimental
%% conditions:
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Make a new copies of our models:
Model_data = Model_FSP;
STL1_data = STL1_FSP;
STL1_4state_data = STL1_4state_FSP;
% Load the experimental data, matching the species name of the model
% ('mRNA') to the appropriate column in the data file
% ('RNA_STL1_total_TS3Full') and filter it so that the only data loaded
% into the model is from 'Replica' = 1 and 'Condition' = '0.2M_NaCl_Step':
Model_data = Model_data.loadData('data/filtered_data_2M_NaCl_Step.csv',...
{'mRNA','RNA_STL1_total_TS3Full'},...
{'Replica',1;'Condition','0.2M_NaCl_Step'});
STL1_data = STL1_data.loadData('data/filtered_data_2M_NaCl_Step.csv',...
{'mRNA','RNA_STL1_total_TS3Full'},...
{'Replica',1;'Condition','0.2M_NaCl_Step'});
STL1_4state_data = ...
STL1_4state_data.loadData('data/filtered_data_2M_NaCl_Step.csv',...
{'mRNA','RNA_STL1_total_TS3Full'},...
{'Replica',1;'Condition','0.2M_NaCl_Step'});
% These plots are unnecessary, as the model parameters have not been fit
% to the data yet. However, it illustrates the improvement to come later:
Model_data.plotFits([],"all",[],{'linewidth',2}, Title='Bursting Gene',...
YLabel='Molecule Count',LegendLocation='northeast', LegendFontSize=12);
STL1_data.plotFits([], "all", [], {'linewidth',2}, Title='STL1',...
YLabel='Molecule Count',LegendLocation='northeast',LegendFontSize=12);
STL1_4state_data.plotFits([], "all", [], {'linewidth',2},...
Title='4-state STL1', YLabel='Molecule Count',...
LegendLocation='northeast', LegendFontSize=12);
%% Save models with loaded data
saveNames = unique({
'Model_data'
'STL1_data'
'STL1_4state_data'
});
save('example_8_LoadingandFittingData_DataLoading',saveNames{:})