Is it possible to assign the values of several species or parameters at once in SimBiology 4.3 (R2013a)?
5 ビュー (過去 30 日間)
古いコメントを表示
I am using the SimBiology GUI and would like to assign the values I have stored in a vector to the species/parameters of my model.
採用された回答
MathWorks Support Team
2013 年 3 月 21 日
You can assign the initial values of all species to the values of a vector as follows:
1. In the SimBiology GUI under Models, right click on your model and select "Export model to Workspace". Unless you already have got a variable called "m1" in the workspace you can leave the variable name as "m1".
2. Assuming you have a column vector "a" with all initial values, convert this vector into a cell array using
points=num2cell(a);
3. Set the Initial amounts of the species to the values of points using
set(m1.Species,{'InitialAmount'},points)
Please note that the order of initial concentrations in the vector needs to be the same as in m1.Species.
The same method can be used to set the values of several parameters at once.
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Extend Modeling Environment についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!