forked from LoLab-MSM/pysb
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix repr() of single-monomer complexes w/ compartments (pysb#550)
* Fix repr() of single-monomer complexes w/ compartments In BNG, a compartment applied to a complex is distinct from one applied to a monomer, by use of prefix and postfix notation. In PySB, one can use parentheses to add a compartment to a complex, but this fails for a complex of length 1. One can use `as_complex_pattern()` to explicitly upgrade to a complex from a monomer, but the string representation and PySB flat exporter currently fail to respect this. A() ** C # Monomer compartment as_complex_pattern(A()) ** C # Complex compartment This PR adds `as_complex_pattern()` around complexes with a single monomer pattern that also have a compartment, to make sure their string representation and PySB flat export works as expected. Co-authored-by: Jeremy Muhlich <jmuhlich@bitflood.org>
- Loading branch information
Showing
3 changed files
with
22 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters