From 13572b42600aad74ceab307725db5b3cb57054e2 Mon Sep 17 00:00:00 2001 From: davidcarslaw Date: Mon, 13 May 2024 13:58:48 +0100 Subject: [PATCH] only calculate cluster stats if a single pollutant --- R/polarCluster.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R/polarCluster.R b/R/polarCluster.R index d597182e..6b34e6a5 100644 --- a/R/polarCluster.R +++ b/R/polarCluster.R @@ -482,7 +482,7 @@ polarCluster <- var_mean <- paste0("mean_", pollutant) var_percent <- paste0(pollutant, "_percent") - if (length(n.clusters) == 1L) { + if (length(n.clusters) == 1L && length(pollutant) == 1L) { clust_stats <- out_data %>%