Can anyone help me in fitting a SVEAIHR epidemic model to the observe data please?

7 views (last 30 days)
I want to fit SVEAIHR epidemic model to a COVID-19 data which has second waves. I want to fit the infection(I) of the model to the daily new cases in the data(column highlighted with yellow colour). Data attached here please.
  1 Comment
Steven Lord
Steven Lord on 25 Jan 2022
Reopening because I think there is some relevant information in the SimBiology documentation that could help this user.

Sign in to comment.

Answers (1)

Florian Augustin
Florian Augustin on 25 Jan 2022
Hi Sonam,
Following up on Steven's comment, here are a few general links that may be helpful for how to fit models to data in SimBiology.
A prerequisite for using SimBiology would be to build a SimBiology model of your SVEAIHR model. The documention for model building in Simbiology may be a good starting point, if your model is not already in SimBiology. Here is a simple example for how to construct a simple model. You can also use the SimBiology Model Builder app to build your model without having to write any code.
To fit the model to your data, you can use SimBiology parameter estimation functions, or use the SimBiology Model Analyzer app to fit the model to data. Here is a collection of examples for different estimation functionalities in SimBiology.
Admittedly, those are a lot of links and information. Feel free to follow up on this thread here if you have specific questions about SimBiology.
I am not sure if this is relevant to your question, but I just wanted to mention that Matlab also has other functions that may be of interest. If you would like to fit a general curve (without using a SimBiology model) to your data, you could take a look at the Curve Fitting toolbox.
Hope this helps,
-Florian
  5 Comments
Sagar Karmakar
Sagar Karmakar on 15 Oct 2022
d(y1)/dt = 1/unnamed*(Reaction1 - Reaction2)
d(y2)/dt = 1/unnamed*(Reaction2 - Reaction3)
d(z)/dt = 1/unnamed*(Reaction3)
This is the model equation for Lotka-Volterra example in SimBiology app where outflow from first equation and inflow in second equation both are reaction2 (c2*Y1*Y2) but in my case they are defferent. I also read the documention for model building in Simbiology but no hint there for the type of model I want to build. Can I build these type of models where reaction fluxes are not same (inflow and outflow fluxes)?
Please help me
Florian Augustin
Florian Augustin on 15 Oct 2022
Hi,
SimBiology has two ways of defining differential equations: reactions and rate rules. Below is an example how you could set up your model (using MATLAB R2022b, but you can use earlier versions as well).
% Create model.
model = sbiomodel("prey-predator");
% Create prey and predator species.
environment = addcompartment(model, "environment", 1);
addspecies(environment, "Prey" , 10);
addspecies(environment, "Predator", 10);
% Create parameters: r, beta, c, mu.
addparameter(model, "r" , 10);
addparameter(model, "beta", 1);
addparameter(model, "c" , 0.1);
addparameter(model, "mu" , 2);
Here is how you can add the dynamics using reactions with mass action kinetic laws and custom reaction rates:
% Add reactions for proliferation and death of prey
prolifPrey = addreaction(model, "Prey -> 2 Prey");
prolifPreyKL = addkineticlaw(prolifPrey, "MassAction");
prolifPreyKL.ParameterVariableNames = "r";
deathPrey = addreaction(model, "Prey -> null");
deathPrey.ReactionRate = "beta*Prey*Predator";
% Add reactions for proliferation and death of predators
prolifPredator = addreaction(model, "null -> Predator");
prolifPredator.ReactionRate = "c*beta*Prey*Predator";
deathPredator = addreaction(model, "Predator -> null");
deathPredatorKL = addkineticlaw(deathPredator, "MassAction");
deathPredatorKL.ParameterVariableNames = "mu";
Alternatively, you can define dynamics using rate rules:
% Alternative: using rate rules.
% addrule(model, "Prey = r*Prey - beta*Prey*Predator", "rate");
% addrule(model, "Predator = c*beta*Prey*Predator - mu*Predator", "rate");
You can simulate and plot the results using sbiosimulate (or a SimFunction) and sbioplot:
simData = sbiosimulate(model);
sbioplot(simData);
Hope this helps,
Florian

Sign in to comment.

Communities

More Answers in the  SimBiology Community

Categories

Find more on Scan Parameter Ranges in Help Center and File Exchange

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!