Skip to content

Commit

Permalink
fIX BUG
Browse files Browse the repository at this point in the history
  • Loading branch information
shubham1637 committed Jan 14, 2021
1 parent 72d54cc commit 61f2023
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion R/align_dia_runs.R
Original file line number Diff line number Diff line change
Expand Up @@ -585,7 +585,11 @@ alignToRef2 <- function(eXp, ref, idx, analytes, fileInfo, XICs, XICs.ref, param
globalFit <- globalFits[[pair]]
adaptiveRT <- params[["RSEdistFactor"]]*RSE[[pair]]

if(any(is.na(XICs.ref.pep)) || any(is.na(XICs.eXp.pep))) return(df.eXp) # Missing values in chromatogram
if(any(sapply(seq_along(XICs.eXp.pep), function(i) any(is.na(XICs.eXp.pep[[i]]))))){
message("Missing values in the chromatogram of ", paste0(analytes, sep = " "), "in run ",
fileInfo[eXp, "runName"])
return(df.eXp) # Missing values in chromatogram
}

tAligned <- tryCatch(expr = getAlignedTimesFast(XICs.ref.pep, XICs.eXp.pep, globalFit, adaptiveRT,
params),
Expand Down

0 comments on commit 61f2023

Please sign in to comment.