reflexive 1.2.6__py3-none-any.whl → 1.2.8__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
reflexive/res.py CHANGED
@@ -125,11 +125,24 @@ class Res_display:
125
125
  df = self._add_res_adj_matrix(df)
126
126
  return df
127
127
 
128
- def show_graph(self,df:DataFrame,inline=True) -> str:
128
+ def show_graph(self,df:DataFrame,scale=10,inline=True) -> str:
129
129
  for am in df.res_adj_matrix:
130
- g = RES_graph(am)
130
+ if scale > 1:
131
+ sm = self._scale_adj_matrix(am,scale)
132
+ else:
133
+ sm = am
134
+ g = RES_graph(sm)
131
135
  g.show()
132
- return("nothing yet")
136
+ return ""
137
+
138
+ def _scale_adj_matrix(self,adj_matrix,scale):
139
+ new_adj = []
140
+ for row in adj_matrix:
141
+ new_row = []
142
+ for c in row:
143
+ new_row.append(round(c*scale,1))
144
+ new_adj.append(new_row)
145
+ return new_adj
133
146
 
134
147
  def _add_res_sequence(self,df):
135
148
  temp_df = df.copy()
@@ -190,7 +203,7 @@ class Res_display:
190
203
  max_count = max(interactions.values())
191
204
  weights = dict()
192
205
  for edge,count in interactions.items():
193
- weights[edge] = round(count/(15*max_count),3)
206
+ weights[edge] = round(count/(max_count),2)
194
207
  return weights
195
208
 
196
209
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: reflexive
3
- Version: 1.2.6
3
+ Version: 1.2.8
4
4
  Summary: Supports AWS Reflexive Expressions Systems (RES) Analysis
5
5
  Project-URL: Repository, https://github.com/nlytx/reflexive.git
6
6
  Author-email: Andrew Gibson <andrew@nlytx.io>
@@ -1,12 +1,12 @@
1
1
  reflexive/__init__.py,sha256=x5l8GV_9yC8yJyjTLqiM_WkfuPMLuNgQxF6PIz5MfFU,422
2
2
  reflexive/analyse.py,sha256=CU6mQ8PxQrkOvuSe4mmnuI18jGMkuxql3zLZ1vEeMEY,17466
3
3
  reflexive/cfg.py,sha256=tDPiC9NwpEVoT05_831sMsMfHhJt8pVrSOsgbtzTNDM,4267
4
- reflexive/res.py,sha256=OUuki0BW9_OvHUSR5FLwqiCoQKjTeZa41of8oA4X8dI,7444
4
+ reflexive/res.py,sha256=UAWCQUxdAjL6m-JVB4dFM1mo3EhesD1Z1_B9W3MJxRE,7829
5
5
  reflexive/res_functions.py,sha256=YF45yUF8NYMSC19DFpE0lmV4xyNxv3QqbbzZmdwmFzg,1231
6
6
  reflexive/session.py,sha256=8STWo8sqmWn-1PHcloFbgmLEvd7lsiFTU4t7ESRTsvw,10046
7
7
  reflexive/util.py,sha256=uU7-lqUmiCiCaR85AdNFKXrdrBspjb1Rmd-yThA3fRU,3699
8
8
  reflexive/visualise.py,sha256=pVnsPJOnHiLAIvDDm9P0u6-sGQINC4GVOY9b0GrzTK4,11725
9
- reflexive-1.2.6.dist-info/METADATA,sha256=UFScd71_jEuuXDIbGOScKNbbpEiQiv9cmL-ZD6DVZVE,574
10
- reflexive-1.2.6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
11
- reflexive-1.2.6.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
12
- reflexive-1.2.6.dist-info/RECORD,,
9
+ reflexive-1.2.8.dist-info/METADATA,sha256=5vtj4abKi3FaIbO29SBCJCo90_32ZFNRxyoK2uVhwEM,574
10
+ reflexive-1.2.8.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
11
+ reflexive-1.2.8.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
12
+ reflexive-1.2.8.dist-info/RECORD,,