diff --git a/turbustat/statistics/dendrograms/dendro_stats.py b/turbustat/statistics/dendrograms/dendro_stats.py index 6ce33653..f1f2a4fe 100644 --- a/turbustat/statistics/dendrograms/dendro_stats.py +++ b/turbustat/statistics/dendrograms/dendro_stats.py @@ -75,8 +75,11 @@ def __init__(self, data, header=None, min_deltas='auto', else: self.dendro_params = dendro_params - if min_deltas == 'auto': - self.autoset_min_deltas(num=num_deltas) + if isinstance(min_deltas, str): + if min_deltas == 'auto': + self.autoset_min_deltas(num=num_deltas) + else: + raise ValueError("min_deltas must be 'auto' or None.") else: self.min_deltas = min_deltas