Mercurial > repos > bimib > marea_2
changeset 206:271e2f36349b draft
Uploaded
author | francesco_lapi |
---|---|
date | Wed, 31 Jul 2024 15:33:29 +0000 |
parents | 3098ceac725d |
children | 2c5fe2bf1bd3 |
files | marea_2/flux_to_map.py |
diffstat | 1 files changed, 3 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/marea_2/flux_to_map.py Wed Jul 31 15:13:42 2024 +0000 +++ b/marea_2/flux_to_map.py Wed Jul 31 15:33:29 2024 +0000 @@ -378,7 +378,7 @@ Invalid = "#BEBEBE" # gray, fold-change under treshold UpRegulated = "#ecac68" # red, up-regulated reaction DownRegulated = "#6495ed" # blue, down-regulated reaction - + Transparent = "#FFFFFF00" # white, no enrichment UpRegulatedInv = "#FF0000" # ^^^ different shade of red (actually orange), up-regulated net value for a reversible reaction with # conflicting enrichment in the two directions. @@ -430,6 +430,7 @@ idOpt1, idOpt2 = getArrowHeadElementId(reactionId) self.applyTo(idOpt1, metabMap, self.toStyleStr(downSizedForTips = True)) if idOpt2: self.applyTo(idOpt2, metabMap, self.toStyleStr(downSizedForTips = True)) + else: TRANSPARENT_ARROW.styleReactionElements(metabMap, idOpt2) def getMapReactionId(self, reactionId :str, mindReactionDir :bool) -> str: """ @@ -463,7 +464,7 @@ # was built by brainless organisms so here we are! INVALID_ARROW = Arrow(Arrow.MIN_W, ArrowColor.Invalid) INSIGNIFICANT_ARROW = Arrow(Arrow.MIN_W, ArrowColor.Invalid, isDashed = True) - +TRANSPARENT_ARROW = Arrow(Arrow.MIN_W, ArrowColor.Transparent) def applyRpsEnrichmentToMap(rpsEnrichmentRes :Dict[str, Union[Tuple[float, FoldChange], Tuple[float, FoldChange, float, float]]], metabMap :ET.ElementTree, maxNumericZScore :float) -> None: """ Applies RPS enrichment results to the provided metabolic map.