Skip to content

Commit

Permalink
styler
Browse files Browse the repository at this point in the history
  • Loading branch information
etiennebacher committed Oct 2, 2024
1 parent 34f292a commit 1ae48bc
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 7 deletions.
1 change: 0 additions & 1 deletion R/descriptives.R
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,6 @@ coef_var.default <- function(x, verbose = TRUE, ...) {
coef_var.numeric <- function(x, mu = NULL, sigma = NULL,
method = c("standard", "unbiased", "median_mad", "qcd"),
trim = 0, remove_na = FALSE, n = NULL, ...) {

# TODO: Support weights
if (!missing(x) && all(c(-1, 1) %in% sign(x))) {
insight::format_error("Coefficient of variation only applicable for ratio scale variables.")
Expand Down
2 changes: 1 addition & 1 deletion R/means_by_group.R
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ means_by_group.numeric <- function(x,
weights = NULL,
digits = NULL,
...) {
# validation check for arguments
# validation check for arguments

# "by" must be provided
if (is.null(by)) {
Expand Down
2 changes: 1 addition & 1 deletion R/recode_values.R
Original file line number Diff line number Diff line change
Expand Up @@ -526,4 +526,4 @@ recode_values.data.frame <- function(x,
}

ok
}
}
4 changes: 0 additions & 4 deletions R/skewness_kurtosis.R
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,6 @@ skewness.numeric <- function(x,
iterations = NULL,
verbose = TRUE,
...) {

if (remove_na) x <- x[!is.na(x)]
n <- length(x)
out <- (sum((x - mean(x))^3) / n) / (sum((x - mean(x))^2) / n)^1.5
Expand Down Expand Up @@ -171,7 +170,6 @@ skewness.matrix <- function(x,
type = "2",
iterations = NULL,
...) {

.skewness <- apply(
x,
2,
Expand Down Expand Up @@ -220,7 +218,6 @@ skewness.default <- function(x,
type = "2",
iterations = NULL,
...) {

skewness(
.factor_to_numeric(x),
remove_na = remove_na,
Expand Down Expand Up @@ -348,7 +345,6 @@ kurtosis.default <- function(x,
type = "2",
iterations = NULL,
...) {

kurtosis(
.factor_to_numeric(x),
remove_na = remove_na,
Expand Down

0 comments on commit 1ae48bc

Please sign in to comment.