Skip to content

Commit

Permalink
Merge pull request #170 from MoTrPAC/develop
Browse files Browse the repository at this point in the history
v0.7.6: Improve DMAQC validation
  • Loading branch information
biodavidjm authored Oct 27, 2022
2 parents 8fdd162 + e0558b4 commit e5c0e00
Show file tree
Hide file tree
Showing 71 changed files with 94 additions and 89 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Package: MotrpacBicQC
Type: Package
Title: QC/QA functions for the MoTrPAC community
Version: 0.7.5
Date: 2022-10-21
Version: 0.7.6
Date: 2022-10-27
Author: MoTrPAC Bioinformatics Center
Maintainer: David Jimenez-Morales <davidjm@stanford.edu>
Description: R Package for the analysis of MoTrPAC datasets.
Expand Down
4 changes: 4 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# MotrpacBicQC 0.7.6 (2022-10-27)

* Improve DMAQC validation

# MotrpacBicQC 0.7.5 (2022-10-21)

* Update `write_proteomics` according to latest updates on data/file structure
Expand Down
25 changes: 11 additions & 14 deletions R/validations.R
Original file line number Diff line number Diff line change
Expand Up @@ -263,24 +263,21 @@ check_viallabel_dmaqc <- function(vl_submitted,
# CHECK
samples_missed <- setdiff(dmaqc_labels, vl_submitted)
if( !(is.null(failed_samples) & purrr::is_empty(samples_missed)) ) {
if(setequal(failed_samples, samples_missed)){
if( all(samples_missed %in% failed_samples) ){
if(verbose) message(" + (+) DMAQC CHECK POINT: samples sent to CAS have been processed (with known issues for some samples): OK")
ic <- "OK"
}else{
# Only if it is not empty: if it is empty means that there are extra samples in the CAS site (checked below)
if( !purrr::is_empty(samples_missed) ){
samplesmissedonly <- samples_missed[!(samples_missed %in% failed_samples)]
if(verbose){
message(" - (-) DMAQC CHECK POINT: samples not found in `metadata_results`: FAIL")
message("\t - ", paste(samplesmissedonly, collapse = "\n\t - "))
}
missed_out <- data.frame(vial_label = samplesmissedonly)
missed_out$cas <- cas
out_plot_large <- file.path(normalizePath(out_qc_folder), paste0(outfile_missed_viallabels,"-missed_viallabels-in-cas.txt"))
write.table(missed_out, out_plot_large, row.names = FALSE, sep = "\t", quote = FALSE)
if(verbose) message(" - ( ) File `", paste0(outfile_missed_viallabels,"-missed_viallabels-in-cas.txt"), "` available with missed vial labels")
ic <- "FAIL"
samplesmissedonly <- samples_missed[!(samples_missed %in% failed_samples)]
if(verbose){
message(" - (-) DMAQC CHECK POINT: samples not found in `metadata_results`: FAIL")
message("\t - ", paste(samplesmissedonly, collapse = "\n\t - "))
}
missed_out <- data.frame(vial_label = samplesmissedonly)
missed_out$cas <- cas
out_plot_large <- file.path(normalizePath(out_qc_folder), paste0(outfile_missed_viallabels,"-missed_viallabels-in-cas.txt"))
write.table(missed_out, out_plot_large, row.names = FALSE, sep = "\t", quote = FALSE)
if(verbose) message(" - ( ) File `", paste0(outfile_missed_viallabels,"-missed_viallabels-in-cas.txt"), "` available with missed vial labels")
ic <- "FAIL"
}
}else{
if( !purrr::is_empty(samples_missed) ){
Expand Down
2 changes: 1 addition & 1 deletion docs/404.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/LICENSE-text.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/articles/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions docs/articles/other_functions.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="generator" content="pandoc">
<meta name="date" content="2022-10-21">
<meta name="date" content="2022-10-27">
<title>MotrpacBicQC: Other Functions</title>
<script src="other_functions_files/header-attrs-2.16/header-attrs.js"></script><script src="other_functions_files/jquery-3.6.0/jquery-3.6.0.min.js"></script><meta name="viewport" content="width=device-width, initial-scale=1">
<link href="other_functions_files/bootstrap-3.3.7/css/bootstrap.min.css" rel="stylesheet">
Expand Down Expand Up @@ -123,7 +123,7 @@ <h1 class="title">MotrpacBicQC: Other Functions</h1>

<p class="authors">
</p>
<p class="date"><span class="glyphicon glyphicon-calendar"></span> 2022-10-21</p>
<p class="date"><span class="glyphicon glyphicon-calendar"></span> 2022-10-27</p>



Expand Down
4 changes: 2 additions & 2 deletions docs/articles/qc_metabolomics.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="generator" content="pandoc">
<meta name="date" content="2022-10-21">
<meta name="date" content="2022-10-27">
<title>MotrpacBicQC: Metabolomics QC</title>
<script src="qc_metabolomics_files/header-attrs-2.16/header-attrs.js"></script><script src="qc_metabolomics_files/jquery-3.6.0/jquery-3.6.0.min.js"></script><meta name="viewport" content="width=device-width, initial-scale=1">
<link href="qc_metabolomics_files/bootstrap-3.3.7/css/bootstrap.min.css" rel="stylesheet">
Expand Down Expand Up @@ -125,7 +125,7 @@ <h1 class="title">MotrpacBicQC: Metabolomics QC</h1>

<p class="authors">
</p>
<p class="date"><span class="glyphicon glyphicon-calendar"></span> 2022-10-21</p>
<p class="date"><span class="glyphicon glyphicon-calendar"></span> 2022-10-27</p>



Expand Down
4 changes: 2 additions & 2 deletions docs/articles/qc_proteomics.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta charset="utf-8">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="generator" content="pandoc">
<meta name="date" content="2022-10-21">
<meta name="date" content="2022-10-27">
<title>MotrpacBicQC: Proteomics QC</title>
<script src="qc_proteomics_files/header-attrs-2.16/header-attrs.js"></script><script src="qc_proteomics_files/jquery-3.6.0/jquery-3.6.0.min.js"></script><meta name="viewport" content="width=device-width, initial-scale=1">
<link href="qc_proteomics_files/bootstrap-3.3.7/css/bootstrap.min.css" rel="stylesheet">
Expand Down Expand Up @@ -125,7 +125,7 @@ <h1 class="title">MotrpacBicQC: Proteomics QC</h1>

<p class="authors">
</p>
<p class="date"><span class="glyphicon glyphicon-calendar"></span> 2022-10-21</p>
<p class="date"><span class="glyphicon glyphicon-calendar"></span> 2022-10-27</p>



Expand Down
6 changes: 3 additions & 3 deletions docs/authors.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 5 additions & 1 deletion docs/news/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/notes_developers.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ articles:
other_functions: other_functions.html
qc_metabolomics: qc_metabolomics.html
qc_proteomics: qc_proteomics.html
last_built: 2022-10-21T19:54Z
last_built: 2022-10-27T18:51Z

2 changes: 1 addition & 1 deletion docs/reference/assay_abbr.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/assay_codes.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/assay_order.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/bic_animal_tissue_code.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_failedsamples.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_manifest_rawdata.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_metadata_metabolites.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_metadata_samples.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_ratio_proteomics.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_results.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_rii_proteomics.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_vial_metadata_proteomics.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/check_viallabel_dmaqc.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/combine_metabolomics_batch.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/create_folder.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/filter_required_columns.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/generate_phase_details.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/get_and_validate_mdd.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/group_abbr.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/group_cols.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/reference/index.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit e5c0e00

Please sign in to comment.