MATLAB Answers

How to assign to a SimBiology model a parameter value (known and constant) changing for each data in the dataset for a non-linear mixed effect estimation?

1 view (last 30 days)
Micaela
Micaela on 23 Aug 2016
Answered: Sietse Braakman on 9 Jan 2019
I’m interested in performing a non-linear mixed effect estimation of a compartmental model. Besides the four parameters to be estimated, the model has two parameters which need to be fixed and which assume a different value for each subject in the dataset. Is there any way to change the value of the fixed parameter for each subject in the dataset?
Thank you!

  0 Comments

Sign in to comment.

Answers (2)

Arthur Goldsipe
Arthur Goldsipe on 24 Aug 2016
Hi Micaela,
Currently, the only information that can be fixed and different for each subject is the dosing. As a workaround, you could try to translate this subject-specific information into "dummy dosing." Let me warn you in advance that this is a pretty painful workaround. We hope to implement a better solution in a future release. But until then, here's how you might implement a workaround:
  • Add a dummy species to the model to store the subject-specific value. (You must use a species, because doses can only change species.)
  • Set the species initial value to 0, and set the units to mole or some other amount unit. (I suggest avoiding concentration units to avoid the complications associated with scaling of concentrations by compartment volume.)
  • Create one dose per patient that targets this new species and sets the amount to the appropriate numeric value.
If your model uses DimensionalAnalysis or UnitConversion, you may also need to convert this dummy species to a parameter with more appropriate units. To do so, perform the following additional steps:
  • Add a parameter to the model with the appropriate name and units.
  • Set ConstantValue to false for this parameter.
  • Create a parameter to act as a conversion factor. Set the Value to 1 and the ValueUnits to "(desired units)/(species units)". For example, if the dummy species has units of "mole" but the desired units are second, set this parameter's units to "second/mole".
  • Add a repeated assignment rule to set the parameter value. For example, if the dummmy species is named "dummySpecies", the actual parameter is name "k1", and the conversion factor is named "conversion1", then the repeated assignment rule would be "k1 = dummySepcies*conversion1".
Good luck,
-Arthur

  1 Comment

Anne Smith
Anne Smith on 8 Jan 2019
I am wondering if there is an alternative to this dummy dosing workaround in the newer versions of MATLAB?
-Anne

Sign in to comment.


Sietse Braakman
Sietse Braakman on 9 Jan 2019
Hi Anne,
As of 2018b, there is no easier way to achieve this, other than the method described by Arthur above. We are aware that this is a workflow many are interested in, so we hope to implement a better solution in the future.
Sietse

  0 Comments

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!