Info
This question is closed. Reopen it to edit or answer.
update a part of a file through other file content
2 views (last 30 days)
Show older comments
Hi, I am running a toolbox, where I am providing parameters along with many other values as an input file. After first estimation run, I want to update a part of my input file from one of the file content generated as an output in workspace.
My input file looks like-
********** MODEL STATES
d/dt(mi) = ksyn_mi * NFKB - kdeg_mi * mi
d/dt(M) = 0
********** MODEL PARAMETERS
ksyn_mi1 = 1
kdeg1_mi1 = 1
kdeg2_mi1 = 1
ksyn_I = 0.0961
kdeg_I = 0.0961
kph1_I = 1
********** MODEL VARIABLES
********** MODEL REACTIONS
********** MODEL FUNCTIONS
In this file, I want to replace the values inside ****** MODEL PARAMETERS and ******** MODEL VARIABLES in each new estimation run, rest of the part will remain the same. And I also want to know that how can I access the workspace output folder in my code to replace input file content?
1 Comment
Jan
on 30 Sep 2015
What is "the workspace output folder"? The solution is trivial: Import the file, apply the required changes, write the file. A more specific question would allow to answer with more details. So please show us, what you have tried so far and explain, which problems occur.
Answers (0)
This question is closed.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!