How to set the time sample with Simbiology
显示 更早的评论
Hi, My current problem is to fit a theoretical model for a chemical reaction (with 2 unknown parameters) to a bench of data. TO do that, I use Simbiology, where I define my reaction. Then I run the simulation with the function sbiosimulate. I have written an handle function @to_fit, wich gives me this theoretical solution. Then, I use the function lsqcurvefit to fit my function to_fit to the data. But my problem is that the vector returned by @to_fit doesn't have the same size than my data vector (it is the same time interval [0 90], but not the same number of points) . How could I choose the vector time in the function sbiosimulate ?
I hope my description is clear enough,
Thanks
回答(1 个)
Razvan
2011-6-23
You can use resample like this
newSimDataObj = resample(simDataObj, timeVectorOfExpData);
You can also fit the parameters of the model using sbioparamestim. Check the examples from here: http://www.mathworks.com/help/toolbox/simbio/ref/sbioparamestim.html
Best, Razvan
1 个评论
Arthur Goldsipe
2012-7-11
As of R2012a, there is also a new property on a model's configuration set titled OutputTimes that can be used to control the time values returned from a simulation: http://www.mathworks.com/help/toolbox/simbio/ref/outputtimes.html
社区
更多回答在 SimBiology Community
类别
在 帮助中心 和 File Exchange 中查找有关 Scan Parameter Ranges 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!