Skip to content

Commit

Permalink
fix: summarizor() don't stop anymore if table only contain discrete…
Browse files Browse the repository at this point in the history
… columns

#588
  • Loading branch information
davidgohel committed Nov 15, 2023
1 parent 2227063 commit e4a0cb2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: flextable
Type: Package
Title: Functions for Tabular Reporting
Version: 0.9.4
Version: 0.9.5.001
Authors@R: c(
person("David", "Gohel", role = c("aut", "cre"),
email = "[email protected]"),
Expand Down
6 changes: 6 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# flextable 0.9.5

## Issues

- `summarizor()` don't stop anymore if table only contain discrete columns.

# flextable 0.9.4

## Issues
Expand Down
2 changes: 2 additions & 0 deletions R/summarizor.R
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,8 @@ dataset_describe <- function(dataset) {
colnames(z) <- c("stat", "cts")
z$percent <- z$cts / sum(z$cts)
z$data_type <- "discrete"
z$value1 <- rep(NA_real_, nrow(z))
z$value2 <- rep(NA_real_, nrow(z))
z
} else if (is.numeric(x)) {
z <- data.frame(
Expand Down

0 comments on commit e4a0cb2

Please sign in to comment.