-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reference point when resolving relative object paths in event assignments #2198
Comments
Is it a use case for a new keyword? :D I think the current behavior (assignment is the local reference point) follows the logic of the relative path concept within the suite. Changing this behavior would also break many things, I guess. For example, adding the amount of water of an oral application to the total liquid volume in stomach is given by the formula:
I see how the solution you proposed can make certain things easier. So maybe we should indeed introduce a new keyword, like |
So definitely not a bug for me. |
yeah, you are right, these are 2 different use cases and the current use case would not work anymore. |
At the moment, when the object references in event assignments formulas are resolved, the reference assignment itself is used as the reference point (and not the assigned entity).
I think this is wrong and should be changed.
E.g. check this example and try to create a simulation: Event_Assignment_Path_Resolution.zip
In my spatial structure, I have 2 containers under Organism : Organ1 and Organ2.
Both containers have parameters P1 and P2.
I define a new event, which should set P1 := P2 in both organs (with P2 from the same organ as P1).
So I define a formula
P2
with P2 referenced as..|P2
and use this formula in both event assignments:Now when trying to create a simulation, I get 2 errors below (1 error per event assignment), which show that the object reference "
..|P2
" is being resolved relative to the event assignment and not relative toOrganism|OrganX|P1
So now I would need to define 2 different formulas - one for each event assignment, where I reference the parameter P1 e.g. with its absolute path (
Organism|Organ1|P1
for the 1st assignment andOrganism|Organ2|P1
for the 2nd).This is very inconvenient and should be changed (e.g. with the status quo we cannot avoid formulas duplication described in Open-Systems-Pharmacology/PK-Sim#2856)
The text was updated successfully, but these errors were encountered: