I am modeling a long-acting release form and my absorption model can’t fit very well. I am trying to use time-varying residual error model to fix my absorption phase.
My approach is like below: first create a categorical variable using absTime = if(Time__hr_<=24,1,0), then using two seperate proportional error terms for the absorption and distribution phase:
This approach works, I am wondering is there a way that I can code directly in PML (without creating the dummy variable absTime), maybe use if else statement?
I guess if two lines of code were used to define the same variable, the latter one will cover the first one. Like in our case, stparm(CMultStdev = tvCMultStdev)was ignored.
you are right, the latter one will cover the first one, but this could be confusing for the users. Moreover, some reference from PML User’s guide:
in a PML model, the statements are not sequential, they are descriptive of the problem.
They do not take action at a point in time. Rather they apply “all the time”. So in PML code, outside of sequence blocks (and assignment statements), relative order of statements does not matter.
so I would not bet about right stparm statement in case of multiple usage.