fixed lint errors
This commit is contained in:
@@ -237,7 +237,7 @@ def cluster_sr_zones(
|
||||
|
||||
for level in sorted_levels[1:]:
|
||||
# Compute current cluster midpoint
|
||||
prices = [l["price_level"] for l in current_cluster]
|
||||
prices = [lvl["price_level"] for lvl in current_cluster]
|
||||
cluster_low = min(prices)
|
||||
cluster_high = max(prices)
|
||||
cluster_mid = (cluster_low + cluster_high) / 2.0
|
||||
@@ -259,11 +259,11 @@ def cluster_sr_zones(
|
||||
# 3. Compute zone for each cluster
|
||||
zones: list[dict] = []
|
||||
for cluster in clusters:
|
||||
prices = [l["price_level"] for l in cluster]
|
||||
prices = [lvl["price_level"] for lvl in cluster]
|
||||
low = min(prices)
|
||||
high = max(prices)
|
||||
midpoint = (low + high) / 2.0
|
||||
strength = min(100, sum(l["strength"] for l in cluster))
|
||||
strength = min(100, sum(lvl["strength"] for lvl in cluster))
|
||||
level_count = len(cluster)
|
||||
|
||||
# 4. Tag zone type
|
||||
|
||||
Reference in New Issue
Block a user