From 2c4aace4488768ea2835c137e71583253d4d5b48 Mon Sep 17 00:00:00 2001 From: Daniel Date: Sun, 13 Aug 2023 11:53:33 +0200 Subject: [PATCH] Update row_means.R --- R/row_means.R | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/R/row_means.R b/R/row_means.R index f078f16df..a0c104d36 100644 --- a/R/row_means.R +++ b/R/row_means.R @@ -117,10 +117,10 @@ row_means <- function(data, # proceed here if min_valid is not NULL if (!is.null(min_valid)) { - # is 'n' indicating a proportion? + # is 'min_valid' indicating a proportion? decimals <- min_valid %% 1 if (decimals != 0) { - n <- round(ncol(data) * decimals) + min_valid <- round(ncol(data) * decimals) } # min_valid may not be larger as df's amount of columns