Skip to content

Commit

Permalink
data.table oriented workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Mickaël Canouil committed Jul 23, 2020
1 parent 12b6151 commit b939224
Show file tree
Hide file tree
Showing 9 changed files with 254 additions and 140 deletions.
6 changes: 5 additions & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,12 @@ Depends:
Imports:
data.table (>= 1.12.8),
flashpcaR (>= 2.1),
fs (>= 1.4.1),
ggforce (>= 0.3.2),
ggplot2 (>= 3.3.2),
gt (>= 0.2.1)
ggtext (>= 0.1.0),
gt (>= 0.2.1),
patchwork (>= 1.0.1)
Suggests:
roxygen2 (>= 7.1.0)
Remotes:
Expand Down
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ export(pca_report)
import(data.table)
import(ggplot2)
import(gt)
import(patchwork)
8 changes: 6 additions & 2 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
# rain (development version)

## Breaking CHanges
## Breaking Changes

* In `R/pca_report.R`,
+ Code refactoring.
+ Code refactoring using `data.table`.
* In `R/compute_pca.R`,
+ Code refactoring using `data.table`.
+ Tweak ethnicity figure.
+ Add an ethnicity figure focussing on the studied cohort.

# rain 0.4.1

Expand Down
15 changes: 7 additions & 8 deletions R/check_bin.R
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,17 @@
check_bin <- function(bin_path) {
if (!all(sapply(bin_path, file.exists))) {
message_prefix <- "[rain] "
text <- paste0(
names(bin_path[!sapply(bin_path, file.exists)]),
' ("', bin_path[!sapply(bin_path, file.exists)], '")'
)
stop(
message_prefix,
paste0(
"No binary found for the following tools: ",
glue::glue_collapse(
x = paste0(
names(bin_path[!sapply(bin_path, file.exists)]),
' ("', bin_path[!sapply(bin_path, file.exists)], '")'
),
sep = ", ",
last = " and "
),
paste(text[-length(text)], collapse = ", "),
" and ",
text[length(text)],
"!"
)
)
Expand Down
Loading

0 comments on commit b939224

Please sign in to comment.