risk-network 0.0.7b8__py3-none-any.whl → 0.0.7b10__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.
risk/__init__.py CHANGED
@@ -7,4 +7,4 @@ RISK: RISK Infers Spatial Kinships
7
7
 
8
8
  from risk.risk import RISK
9
9
 
10
- __version__ = "0.0.7-beta.8"
10
+ __version__ = "0.0.7-beta.10"
@@ -177,19 +177,18 @@ def get_description(words_column: pd.Series) -> str:
177
177
  all_words = words_column.str.cat(sep=" ")
178
178
  tokens = word_tokenize(all_words)
179
179
 
180
- # Check if all tokens are numeric strings or contain a mixture of strings and numbers
180
+ # Separate numeric tokens
181
181
  numeric_tokens = [token for token in tokens if token.replace(".", "", 1).isdigit()]
182
- non_numeric_tokens = [token for token in tokens if not token.replace(".", "", 1).isdigit()]
183
182
  # If there's only one unique numeric value, return it directly as a string
184
183
  unique_numeric_values = set(numeric_tokens)
185
184
  if len(unique_numeric_values) == 1:
186
185
  return f"{list(unique_numeric_values)[0]}"
187
186
 
188
- # Allow the inclusion of both alphabetic and numeric tokens if mixture is detected
187
+ # Ensure that all values in 'words' are strings and include both alphabetic and numeric tokens
189
188
  words = [
190
- (
189
+ str(
191
190
  word.lower() if word.istitle() else word
192
- ) # Lowercase all words except proper nouns (e.g., RNA, mRNA)
191
+ ) # Convert to string and lowercase all words except proper nouns (e.g., RNA, mRNA)
193
192
  for word in tokens
194
193
  if word.isalpha()
195
194
  or word.replace(".", "", 1).isdigit() # Keep alphabetic words and numeric strings
@@ -263,11 +262,11 @@ def _generate_coherent_description(words: List[str]) -> str:
263
262
  Returns:
264
263
  str: A coherent description formed by arranging the words in a logical sequence.
265
264
  """
266
- # If there are no words or the input is invalid, raise an error
267
- if not words or not isinstance(words, list) or not all(isinstance(word, str) for word in words):
268
- raise ValueError("Input must be a list of strings.")
265
+ # If there are no words, return a keyword indicating no data is available
266
+ if not words:
267
+ return "N/A"
269
268
 
270
- # If there's only one unique word, return it directly (even if it's a number-like string)
269
+ # If there's only one unique word, return it directly
271
270
  unique_words = set(words)
272
271
  if len(unique_words) == 1:
273
272
  return list(unique_words)[0]
risk/annotations/io.py CHANGED
@@ -12,7 +12,7 @@ import networkx as nx
12
12
  import pandas as pd
13
13
 
14
14
  from risk.annotations.annotations import load_annotations
15
- from risk.log import params, print_header
15
+ from risk.log import params, logger, log_header
16
16
 
17
17
 
18
18
  class AnnotationsIO:
@@ -218,7 +218,7 @@ def _log_loading(filetype: str, filepath: str = "") -> None:
218
218
  filetype (str): The type of the file being loaded (e.g., 'Cytoscape').
219
219
  filepath (str, optional): The path to the file being loaded.
220
220
  """
221
- print_header("Loading annotations")
222
- print(f"Filetype: {filetype}")
221
+ log_header("Loading annotations")
222
+ logger.debug(f"Filetype: {filetype}")
223
223
  if filepath:
224
- print(f"Filepath: {filepath}")
224
+ logger.debug(f"Filepath: {filepath}")
risk/log/__init__.py CHANGED
@@ -3,7 +3,7 @@ risk/log
3
3
  ~~~~~~~~
4
4
  """
5
5
 
6
- from .console import print_header
6
+ from .config import logger, log_header, set_global_verbosity
7
7
  from .params import Params
8
8
 
9
9
  params = Params()
risk/log/config.py ADDED
@@ -0,0 +1,49 @@
1
+ """
2
+ risk/log/config
3
+ ~~~~~~~~~~~~~~~
4
+ """
5
+
6
+ import logging
7
+
8
+ # Create a global logger
9
+ logger = logging.getLogger("risk_logger")
10
+ logger.setLevel(logging.DEBUG) # Start with the highest level; adjust as needed
11
+ # Create a console handler
12
+ console_handler = logging.StreamHandler()
13
+ console_handler.setLevel(logging.DEBUG) # Set the handler level (can be controlled later)
14
+ # Create a formatter and set it for the handler
15
+ formatter = logging.Formatter("%(message)s")
16
+ console_handler.setFormatter(formatter)
17
+
18
+ # Add the handler to the logger if it doesn't already exist
19
+ if not logger.hasHandlers():
20
+ logger.addHandler(console_handler)
21
+
22
+
23
+ def set_global_verbosity(verbose):
24
+ """Set the global verbosity level for the logger.
25
+
26
+ Args:
27
+ verbose (bool): Whether to display all log messages (True) or only error messages (False).
28
+
29
+ Returns:
30
+ None
31
+ """
32
+ if verbose:
33
+ logger.setLevel(logging.DEBUG) # Show all messages
34
+ console_handler.setLevel(logging.DEBUG)
35
+ else:
36
+ logger.setLevel(logging.ERROR) # Show only error messages
37
+ console_handler.setLevel(logging.ERROR)
38
+
39
+
40
+ def log_header(input_string: str) -> None:
41
+ """Log the input string as a header with a line of dashes above and below it.
42
+
43
+ Args:
44
+ input_string (str): The string to be printed as a header.
45
+ """
46
+ border = "-" * len(input_string)
47
+ logger.info(border)
48
+ logger.info(input_string)
49
+ logger.info(border)
risk/log/params.py CHANGED
@@ -12,7 +12,7 @@ from typing import Any, Dict
12
12
 
13
13
  import numpy as np
14
14
 
15
- from .console import print_header
15
+ from .config import logger, log_header
16
16
 
17
17
  # Suppress all warnings - this is to resolve warnings from multiprocessing
18
18
  warnings.filterwarnings("ignore")
@@ -35,11 +35,11 @@ def _safe_param_export(func):
35
35
  filepath = (
36
36
  kwargs.get("filepath") or args[1]
37
37
  ) # Assuming filepath is always the second argument
38
- print(f"Parameters successfully exported to filepath: {filepath}")
38
+ logger.info(f"Parameters successfully exported to filepath: {filepath}")
39
39
  return result
40
40
  except Exception as e:
41
41
  filepath = kwargs.get("filepath") or args[1]
42
- print(f"An error occurred while exporting parameters to {filepath}: {e}")
42
+ logger.error(f"An error occurred while exporting parameters to {filepath}: {e}")
43
43
  return None
44
44
 
45
45
  return wrapper
@@ -161,7 +161,7 @@ class Params:
161
161
  Returns:
162
162
  dict: A dictionary containing the processed parameters.
163
163
  """
164
- print_header("Loading parameters")
164
+ log_header("Loading parameters")
165
165
  return _convert_ndarray_to_list(
166
166
  {
167
167
  "annotations": self.annotations,
@@ -15,6 +15,7 @@ from sklearn.metrics import silhouette_score
15
15
 
16
16
  from risk.annotations import get_description
17
17
  from risk.constants import GROUP_LINKAGE_METHODS, GROUP_DISTANCE_METRICS
18
+ from risk.log import logger
18
19
 
19
20
 
20
21
  def define_domains(
@@ -45,10 +46,10 @@ def define_domains(
45
46
  )
46
47
  # Perform hierarchical clustering
47
48
  Z = linkage(m, method=best_linkage, metric=best_metric)
48
- print(
49
+ logger.debug(
49
50
  f"Linkage criterion: '{linkage_criterion}'\nLinkage method: '{best_linkage}'\nLinkage metric: '{best_metric}'"
50
51
  )
51
- print(f"Optimal linkage threshold: {round(best_threshold, 3)}")
52
+ logger.debug(f"Optimal linkage threshold: {round(best_threshold, 3)}")
52
53
  # Calculate the optimal threshold for clustering
53
54
  max_d_optimal = np.max(Z[:, 2]) * best_threshold
54
55
  # Assign domains to the annotations matrix
@@ -58,7 +59,9 @@ def define_domains(
58
59
  except ValueError:
59
60
  # If a ValueError is encountered, handle it by assigning unique domains
60
61
  n_rows = len(top_annotations)
61
- print(f"Error encountered. Skipping clustering and assigning {n_rows} unique domains.")
62
+ logger.error(
63
+ f"Error encountered. Skipping clustering and assigning {n_rows} unique domains."
64
+ )
62
65
  top_annotations["domain"] = range(1, n_rows + 1) # Assign unique domains
63
66
 
64
67
  # Create DataFrames to store domain information
@@ -20,6 +20,7 @@ from risk.neighborhoods.community import (
20
20
  calculate_spinglass_neighborhoods,
21
21
  calculate_walktrap_neighborhoods,
22
22
  )
23
+ from risk.log import logger
23
24
 
24
25
  # Suppress DataConversionWarning
25
26
  warnings.filterwarnings(action="ignore", category=DataConversionWarning)
@@ -129,7 +130,7 @@ def process_neighborhoods(
129
130
  enrichment_matrix = neighborhoods["enrichment_matrix"]
130
131
  binary_enrichment_matrix = neighborhoods["binary_enrichment_matrix"]
131
132
  significant_enrichment_matrix = neighborhoods["significant_enrichment_matrix"]
132
- print(f"Imputation depth: {impute_depth}")
133
+ logger.debug(f"Imputation depth: {impute_depth}")
133
134
  if impute_depth:
134
135
  (
135
136
  enrichment_matrix,
@@ -142,7 +143,7 @@ def process_neighborhoods(
142
143
  max_depth=impute_depth,
143
144
  )
144
145
 
145
- print(f"Pruning threshold: {prune_threshold}")
146
+ logger.debug(f"Pruning threshold: {prune_threshold}")
146
147
  if prune_threshold:
147
148
  (
148
149
  enrichment_matrix,
risk/network/io.py CHANGED
@@ -16,7 +16,7 @@ import networkx as nx
16
16
  import pandas as pd
17
17
 
18
18
  from risk.network.geometry import assign_edge_lengths
19
- from risk.log import params, print_header
19
+ from risk.log import params, logger, log_header
20
20
 
21
21
 
22
22
  class NetworkIO:
@@ -57,9 +57,8 @@ class NetworkIO:
57
57
  weight_label=weight_label,
58
58
  )
59
59
 
60
- @classmethod
60
+ @staticmethod
61
61
  def load_gpickle_network(
62
- cls,
63
62
  filepath: str,
64
63
  compute_sphere: bool = True,
65
64
  surface_depth: float = 0.0,
@@ -80,7 +79,7 @@ class NetworkIO:
80
79
  Returns:
81
80
  nx.Graph: Loaded and processed network.
82
81
  """
83
- networkio = cls(
82
+ networkio = NetworkIO(
84
83
  compute_sphere=compute_sphere,
85
84
  surface_depth=surface_depth,
86
85
  min_edges_per_node=min_edges_per_node,
@@ -109,9 +108,8 @@ class NetworkIO:
109
108
  # Initialize the graph
110
109
  return self._initialize_graph(G)
111
110
 
112
- @classmethod
111
+ @staticmethod
113
112
  def load_networkx_network(
114
- cls,
115
113
  network: nx.Graph,
116
114
  compute_sphere: bool = True,
117
115
  surface_depth: float = 0.0,
@@ -132,7 +130,7 @@ class NetworkIO:
132
130
  Returns:
133
131
  nx.Graph: Loaded and processed network.
134
132
  """
135
- networkio = cls(
133
+ networkio = NetworkIO(
136
134
  compute_sphere=compute_sphere,
137
135
  surface_depth=surface_depth,
138
136
  min_edges_per_node=min_edges_per_node,
@@ -158,9 +156,8 @@ class NetworkIO:
158
156
  # Initialize the graph
159
157
  return self._initialize_graph(network)
160
158
 
161
- @classmethod
159
+ @staticmethod
162
160
  def load_cytoscape_network(
163
- cls,
164
161
  filepath: str,
165
162
  source_label: str = "source",
166
163
  target_label: str = "target",
@@ -187,7 +184,7 @@ class NetworkIO:
187
184
  Returns:
188
185
  nx.Graph: Loaded and processed network.
189
186
  """
190
- networkio = cls(
187
+ networkio = NetworkIO(
191
188
  compute_sphere=compute_sphere,
192
189
  surface_depth=surface_depth,
193
190
  min_edges_per_node=min_edges_per_node,
@@ -312,9 +309,8 @@ class NetworkIO:
312
309
  if os.path.exists(tmp_dir):
313
310
  shutil.rmtree(tmp_dir)
314
311
 
315
- @classmethod
312
+ @staticmethod
316
313
  def load_cytoscape_json_network(
317
- cls,
318
314
  filepath: str,
319
315
  source_label: str = "source",
320
316
  target_label: str = "target",
@@ -339,7 +335,7 @@ class NetworkIO:
339
335
  Returns:
340
336
  NetworkX graph: Loaded and processed network.
341
337
  """
342
- networkio = cls(
338
+ networkio = NetworkIO(
343
339
  compute_sphere=compute_sphere,
344
340
  surface_depth=surface_depth,
345
341
  min_edges_per_node=min_edges_per_node,
@@ -455,10 +451,10 @@ class NetworkIO:
455
451
  # Log the number of nodes and edges before and after cleaning
456
452
  num_final_nodes = G.number_of_nodes()
457
453
  num_final_edges = G.number_of_edges()
458
- print(f"Initial node count: {num_initial_nodes}")
459
- print(f"Final node count: {num_final_nodes}")
460
- print(f"Initial edge count: {num_initial_edges}")
461
- print(f"Final edge count: {num_final_edges}")
454
+ logger.debug(f"Initial node count: {num_initial_nodes}")
455
+ logger.debug(f"Final node count: {num_final_nodes}")
456
+ logger.debug(f"Initial edge count: {num_initial_edges}")
457
+ logger.debug(f"Final edge count: {num_final_edges}")
462
458
 
463
459
  def _assign_edge_weights(self, G: nx.Graph) -> None:
464
460
  """Assign weights to the edges in the graph.
@@ -476,7 +472,7 @@ class NetworkIO:
476
472
  ) # Default to 1.0 if 'weight' not present
477
473
 
478
474
  if self.include_edge_weight and missing_weights:
479
- print(f"Total edges missing weights: {missing_weights}")
475
+ logger.debug(f"Total edges missing weights: {missing_weights}")
480
476
 
481
477
  def _validate_nodes(self, G: nx.Graph) -> None:
482
478
  """Validate the graph structure and attributes.
@@ -514,14 +510,14 @@ class NetworkIO:
514
510
  filetype (str): The type of the file being loaded (e.g., 'CSV', 'JSON').
515
511
  filepath (str, optional): The path to the file being loaded. Defaults to "".
516
512
  """
517
- print_header("Loading network")
518
- print(f"Filetype: {filetype}")
513
+ log_header("Loading network")
514
+ logger.debug(f"Filetype: {filetype}")
519
515
  if filepath:
520
- print(f"Filepath: {filepath}")
521
- print(f"Edge weight: {'Included' if self.include_edge_weight else 'Excluded'}")
516
+ logger.debug(f"Filepath: {filepath}")
517
+ logger.debug(f"Edge weight: {'Included' if self.include_edge_weight else 'Excluded'}")
522
518
  if self.include_edge_weight:
523
- print(f"Weight label: {self.weight_label}")
524
- print(f"Minimum edges per node: {self.min_edges_per_node}")
525
- print(f"Projection: {'Sphere' if self.compute_sphere else 'Plane'}")
519
+ logger.debug(f"Weight label: {self.weight_label}")
520
+ logger.debug(f"Minimum edges per node: {self.min_edges_per_node}")
521
+ logger.debug(f"Projection: {'Sphere' if self.compute_sphere else 'Plane'}")
526
522
  if self.compute_sphere:
527
- print(f"Surface depth: {self.surface_depth}")
523
+ logger.debug(f"Surface depth: {self.surface_depth}")
risk/risk.py CHANGED
@@ -10,7 +10,7 @@ import numpy as np
10
10
  import pandas as pd
11
11
 
12
12
  from risk.annotations import AnnotationsIO, define_top_annotations
13
- from risk.log import params, print_header
13
+ from risk.log import params, logger, log_header, set_global_verbosity
14
14
  from risk.neighborhoods import (
15
15
  define_domains,
16
16
  get_network_neighborhoods,
@@ -33,16 +33,32 @@ class RISK(NetworkIO, AnnotationsIO):
33
33
  and performing network-based statistical analysis, such as neighborhood significance testing.
34
34
  """
35
35
 
36
- def __init__(self, *args, **kwargs):
37
- """Initialize the RISK class with configuration settings."""
36
+ def __init__(self, *args, verbose: bool = True, **kwargs):
37
+ """Initialize the RISK class with configuration settings.
38
+
39
+ Args:
40
+ verbose (bool): If False, suppresses all log messages to the console. Defaults to True.
41
+ *args: Variable length argument list.
42
+ **kwargs: Arbitrary keyword arguments.
43
+
44
+ Note:
45
+ - All *args and **kwargs are passed to NetworkIO's __init__ method.
46
+ - AnnotationsIO does not take any arguments and is initialized without them.
47
+ """
48
+ # Set global verbosity for logging
49
+ set_global_verbosity(verbose)
38
50
  # Initialize and log network parameters
39
51
  params.initialize()
40
- # Initialize the parent classes
52
+ # Use super() to call NetworkIO's __init__ with the given arguments and keyword arguments
41
53
  super().__init__(*args, **kwargs)
42
54
 
43
55
  @property
44
- def params(self):
45
- """Access the logged parameters."""
56
+ def params(self) -> params:
57
+ """Access the logged network parameters.
58
+
59
+ Returns:
60
+ Params: An instance of the Params class with logged parameters and methods to access or update them.
61
+ """
46
62
  return params
47
63
 
48
64
  def load_neighborhoods_by_hypergeom(
@@ -69,7 +85,7 @@ class RISK(NetworkIO, AnnotationsIO):
69
85
  Returns:
70
86
  dict: Computed significance of neighborhoods.
71
87
  """
72
- print_header("Running hypergeometric test")
88
+ log_header("Running hypergeometric test")
73
89
  # Log neighborhood analysis parameters
74
90
  params.log_neighborhoods(
75
91
  distance_metric=distance_metric,
@@ -122,7 +138,7 @@ class RISK(NetworkIO, AnnotationsIO):
122
138
  Returns:
123
139
  dict: Computed significance of neighborhoods.
124
140
  """
125
- print_header("Running Poisson test")
141
+ log_header("Running Poisson test")
126
142
  # Log neighborhood analysis parameters
127
143
  params.log_neighborhoods(
128
144
  distance_metric=distance_metric,
@@ -181,7 +197,7 @@ class RISK(NetworkIO, AnnotationsIO):
181
197
  Returns:
182
198
  dict: Computed significance of neighborhoods.
183
199
  """
184
- print_header("Running permutation test")
200
+ log_header("Running permutation test")
185
201
  # Log neighborhood analysis parameters
186
202
  params.log_neighborhoods(
187
203
  distance_metric=distance_metric,
@@ -205,10 +221,10 @@ class RISK(NetworkIO, AnnotationsIO):
205
221
  )
206
222
 
207
223
  # Log and display permutation test settings
208
- print(f"Neighborhood scoring metric: '{score_metric}'")
209
- print(f"Null distribution: '{null_distribution}'")
210
- print(f"Number of permutations: {num_permutations}")
211
- print(f"Maximum workers: {max_workers}")
224
+ logger.debug(f"Neighborhood scoring metric: '{score_metric}'")
225
+ logger.debug(f"Null distribution: '{null_distribution}'")
226
+ logger.debug(f"Number of permutations: {num_permutations}")
227
+ logger.debug(f"Maximum workers: {max_workers}")
212
228
  # Run permutation test to compute neighborhood significance
213
229
  neighborhood_significance = compute_permutation_test(
214
230
  neighborhoods=neighborhoods,
@@ -260,7 +276,7 @@ class RISK(NetworkIO, AnnotationsIO):
260
276
  NetworkGraph: A fully initialized and processed NetworkGraph object.
261
277
  """
262
278
  # Log the parameters and display headers
263
- print_header("Finding significant neighborhoods")
279
+ log_header("Finding significant neighborhoods")
264
280
  params.log_graph(
265
281
  tail=tail,
266
282
  pval_cutoff=pval_cutoff,
@@ -274,9 +290,9 @@ class RISK(NetworkIO, AnnotationsIO):
274
290
  max_cluster_size=max_cluster_size,
275
291
  )
276
292
 
277
- print(f"p-value cutoff: {pval_cutoff}")
278
- print(f"FDR BH cutoff: {fdr_cutoff}")
279
- print(
293
+ logger.debug(f"p-value cutoff: {pval_cutoff}")
294
+ logger.debug(f"FDR BH cutoff: {fdr_cutoff}")
295
+ logger.debug(
280
296
  f"Significance tail: '{tail}' ({'enrichment' if tail == 'right' else 'depletion' if tail == 'left' else 'both'})"
281
297
  )
282
298
  # Calculate significant neighborhoods based on the provided parameters
@@ -288,7 +304,7 @@ class RISK(NetworkIO, AnnotationsIO):
288
304
  fdr_cutoff=fdr_cutoff,
289
305
  )
290
306
 
291
- print_header("Processing neighborhoods")
307
+ log_header("Processing neighborhoods")
292
308
  # Process neighborhoods by imputing and pruning based on the given settings
293
309
  processed_neighborhoods = process_neighborhoods(
294
310
  network=network,
@@ -297,9 +313,9 @@ class RISK(NetworkIO, AnnotationsIO):
297
313
  prune_threshold=prune_threshold,
298
314
  )
299
315
 
300
- print_header("Finding top annotations")
301
- print(f"Min cluster size: {min_cluster_size}")
302
- print(f"Max cluster size: {max_cluster_size}")
316
+ log_header("Finding top annotations")
317
+ logger.debug(f"Min cluster size: {min_cluster_size}")
318
+ logger.debug(f"Max cluster size: {max_cluster_size}")
303
319
  # Define top annotations based on processed neighborhoods
304
320
  top_annotations = self._define_top_annotations(
305
321
  network=network,
@@ -309,7 +325,7 @@ class RISK(NetworkIO, AnnotationsIO):
309
325
  max_cluster_size=max_cluster_size,
310
326
  )
311
327
 
312
- print_header("Optimizing distance threshold for domains")
328
+ log_header("Optimizing distance threshold for domains")
313
329
  # Define domains in the network using the specified clustering settings
314
330
  domains = self._define_domains(
315
331
  neighborhoods=processed_neighborhoods,
@@ -357,7 +373,7 @@ class RISK(NetworkIO, AnnotationsIO):
357
373
  Returns:
358
374
  NetworkPlotter: A NetworkPlotter object configured with the given parameters.
359
375
  """
360
- print_header("Loading plotter")
376
+ log_header("Loading plotter")
361
377
  # Log the plotter settings
362
378
  params.log_plotter(
363
379
  figsize=figsize,
@@ -398,9 +414,9 @@ class RISK(NetworkIO, AnnotationsIO):
398
414
  else:
399
415
  for_print_distance_metric = distance_metric
400
416
  # Log and display neighborhood settings
401
- print(f"Distance metric: '{for_print_distance_metric}'")
402
- print(f"Edge length threshold: {edge_length_threshold}")
403
- print(f"Random seed: {random_seed}")
417
+ logger.debug(f"Distance metric: '{for_print_distance_metric}'")
418
+ logger.debug(f"Edge length threshold: {edge_length_threshold}")
419
+ logger.debug(f"Random seed: {random_seed}")
404
420
 
405
421
  # Compute neighborhoods based on the network and distance metric
406
422
  neighborhoods = get_network_neighborhoods(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: risk-network
3
- Version: 0.0.7b8
3
+ Version: 0.0.7b10
4
4
  Summary: A Python package for biological network analysis
5
5
  Author: Ira Horecka
6
6
  Author-email: Ira Horecka <ira89@icloud.com>
@@ -1,20 +1,20 @@
1
- risk/__init__.py,sha256=kEtmAgswqdIS5KBKHJO1NZkxJRF6s4ww_cjSOrBuJ4A,112
1
+ risk/__init__.py,sha256=cMQ9biQEb8gYBZtC-NebxpomJpoEQOMHT0jhH6N5dJc,113
2
2
  risk/constants.py,sha256=XInRaH78Slnw_sWgAsBFbUHkyA0h0jL0DKGuQNbOvjM,550
3
- risk/risk.py,sha256=6666BzdMTgOaQl98ZKiJ19c6XBot26eTJ0iIlk-ZCZQ,20515
3
+ risk/risk.py,sha256=JlKkNrdM3LwMl1Wqs3KZDOhnOwGm9EzsquoJ1GBsU0g,21339
4
4
  risk/annotations/__init__.py,sha256=vUpVvMRE5if01Ic8QY6M2Ae3EFGJHdugEe9PdEkAW4Y,138
5
- risk/annotations/annotations.py,sha256=k9LGTL2uqdYvI5F3jU3UKz-O855B-DoazGPMzSn-XUc,11673
6
- risk/annotations/io.py,sha256=lo7NKqOVkeeBp58JBxWJHtA0xjL5Yoxqe9Ox0daKlZk,9457
7
- risk/log/__init__.py,sha256=xuLImfxFlKpnVhzi_gDYlr2_c9cLkrw2c_3iEsXb1as,107
8
- risk/log/console.py,sha256=im9DRExwf6wHlcn9fewoDcKIpo3vPcorZIaNAl-0csY,355
9
- risk/log/params.py,sha256=Rfdg5UcGCrG80m6V79FyORERWUqIzHFO7tGiY4zAImM,6347
5
+ risk/annotations/annotations.py,sha256=3FFyJE9Gp5oRN72_8iVAUnecsmTtx2G2fp5AlCY1oUk,11405
6
+ risk/annotations/io.py,sha256=om_3e26PQmrICY25UJnXuuZ20oXENNlr1QCBmOxYlMI,9475
7
+ risk/log/__init__.py,sha256=aDUz5LMFQsz0UlsQI2EdXtiBKRLfml1UMeZKC7QQIGU,134
8
+ risk/log/config.py,sha256=tYFQ75yyVUYB5WA040037dtOL1SDoDwyGVpkP2P1dZc,1439
9
+ risk/log/params.py,sha256=DUmsqPo9hi3rQHFgLTunP14I-vVoyQSFZbx5aSYmVts,6363
10
10
  risk/neighborhoods/__init__.py,sha256=tKKEg4lsbqFukpgYlUGxU_v_9FOqK7V0uvM9T2QzoL0,206
11
11
  risk/neighborhoods/community.py,sha256=stYYBXeZlGLMV-k8ckQeIqThT6v9y-S3hETobAo9590,6817
12
- risk/neighborhoods/domains.py,sha256=vTCKtRE0oFcY862squrF7_cqCjnckiC9Sl0Qh2FM81k,10665
13
- risk/neighborhoods/neighborhoods.py,sha256=5WVXCZ0f-MzUfDITdNlL0NgDS3DBamdc_ZVPA-p9j7U,18218
12
+ risk/neighborhoods/domains.py,sha256=X-qmnhb7K_CHCrRDBtpBizt8BmyJjKCzKZdh-NSUf_c,10736
13
+ risk/neighborhoods/neighborhoods.py,sha256=M-wL4xB_BUTlSZg90swygO5NdrZ6hFUFqs6jsiZaqHk,18260
14
14
  risk/network/__init__.py,sha256=iEPeJdZfqp0toxtbElryB8jbz9_t_k4QQ3iDvKE8C_0,126
15
15
  risk/network/geometry.py,sha256=H1yGVVqgbfpzBzJwEheDLfvGLSA284jGQQTn612L4Vc,6759
16
16
  risk/network/graph.py,sha256=_LEoom4EEowGALuJKSXcev9RAAHu2FqIeq3u7mkifW0,16479
17
- risk/network/io.py,sha256=gG50kOknO-D3HkW1HsbHMkTMvjUtn3l4W4Jwd-rXNr8,21202
17
+ risk/network/io.py,sha256=ASoKG4vkCC_aHwxlF4502W_SyaaCrRnHsTmRwL00spI,21266
18
18
  risk/network/plot.py,sha256=3OucCoKJwx9M9H4lqAvcQdM9YiCSyIxz21jyqDbpffc,62286
19
19
  risk/stats/__init__.py,sha256=WcgoETQ-hS0LQqKRsAMIPtP15xZ-4eul6VUBuUx4Wzc,220
20
20
  risk/stats/hypergeom.py,sha256=o6Qnj31gCAKxr2uQirXrbv7XvdDJGEq69MFW-ubx_hA,2272
@@ -23,8 +23,8 @@ risk/stats/stats.py,sha256=kvShov-94W6ffgDUTb522vB9hDJQSyTsYif_UIaFfSM,7059
23
23
  risk/stats/permutation/__init__.py,sha256=neJp7FENC-zg_CGOXqv-iIvz1r5XUKI9Ruxhmq7kDOI,105
24
24
  risk/stats/permutation/permutation.py,sha256=kmSZ7bQ-AD0TFiQDgIwfxTeqHa4pjp7fIcOzAqyhUNY,9714
25
25
  risk/stats/permutation/test_functions.py,sha256=HuDIM-V1jkkfE1rlaIqrWWBSKZt3dQ1f-YEDjWpnLSE,2343
26
- risk_network-0.0.7b8.dist-info/LICENSE,sha256=jOtLnuWt7d5Hsx6XXB2QxzrSe2sWWh3NgMfFRetluQM,35147
27
- risk_network-0.0.7b8.dist-info/METADATA,sha256=aFjqRdtk2rsHn0AHuofhj9ZtkFFuuxfgLd_DnyX52qA,43142
28
- risk_network-0.0.7b8.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
29
- risk_network-0.0.7b8.dist-info/top_level.txt,sha256=NX7C2PFKTvC1JhVKv14DFlFAIFnKc6Lpsu1ZfxvQwVw,5
30
- risk_network-0.0.7b8.dist-info/RECORD,,
26
+ risk_network-0.0.7b10.dist-info/LICENSE,sha256=jOtLnuWt7d5Hsx6XXB2QxzrSe2sWWh3NgMfFRetluQM,35147
27
+ risk_network-0.0.7b10.dist-info/METADATA,sha256=H_rRPorQwnrzeJ26vQph8anQHm0GPMjA_N3xro13oxs,43143
28
+ risk_network-0.0.7b10.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
29
+ risk_network-0.0.7b10.dist-info/top_level.txt,sha256=NX7C2PFKTvC1JhVKv14DFlFAIFnKc6Lpsu1ZfxvQwVw,5
30
+ risk_network-0.0.7b10.dist-info/RECORD,,
risk/log/console.py DELETED
@@ -1,16 +0,0 @@
1
- """
2
- risk/log/console
3
- ~~~~~~~~~~~~~~~~
4
- """
5
-
6
-
7
- def print_header(input_string: str) -> None:
8
- """Print the input string as a header with a line of dashes above and below it.
9
-
10
- Args:
11
- input_string (str): The string to be printed as a header.
12
- """
13
- border = "-" * len(input_string)
14
- print(border)
15
- print(input_string)
16
- print(border)