Skip to content

Commit

Permalink
use R.utils to count number of SNPs from *.bim file.
Browse files Browse the repository at this point in the history
  • Loading branch information
Mickaël Canouil committed May 4, 2020
1 parent 6ab0cf7 commit da3b572
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
3 changes: 2 additions & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: rain
Title: Reference-based Ancestry INference
Version: 0.3.4
Version: 0.3.5
Authors@R:
c(person(given = "Mickaël",
family = "Canouil",
Expand Down Expand Up @@ -34,6 +34,7 @@ Imports:
purrr (>= 0.3.3),
readr (>= 1.3.1),
rlang (>= 0.4.2),
R.utils (>= 2.9.2),
scales (>= 1.1.0),
tibble (>= 2.1.3),
tidyr (>= 1.0.0),
Expand Down
6 changes: 6 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

## Minor improvements and fixes

* In `R/compute_pca.R`, use `R.utils` to count number of SNPs from `*.bim` file.

# rain 0.3.4

## Minor improvements and fixes

* In `R/compute_pca.R`, fix number of SNPs in ggplot legend.

# rain 0.3.3
Expand Down
2 changes: 1 addition & 1 deletion R/compute_pca.R
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ compute_pca <- function(cohort_name, input_plink, output_directory, ref1kg_popul
title = "Estimated Ethnicity",
subtitle = paste(
"Based on Principal Component Analysis using",
scales::comma(ncol(res_pca[["projection"]])),
scales::comma(R.utils::countLines(paste0(input_plink, ".bim"))),
"SNPs."
)
)
Expand Down

0 comments on commit da3b572

Please sign in to comment.