diff --git a/R/createTaxonomyMatrix.R b/R/createTaxonomyMatrix.R index 9e2c7b71..8878d863 100644 --- a/R/createTaxonomyMatrix.R +++ b/R/createTaxonomyMatrix.R @@ -118,8 +118,20 @@ getTaxonomyInfo <- function(inputTaxa = NULL, currentNCBIinfo = NULL) { tmp <- list() outList <- list() k <- 1 + missingTaxa <- setdiff(inputTaxa, currentNCBIinfo$ncbiID) + if (length(missingTaxa) > 0) { + warning( + cat(length(missingTaxa), + "id(s) missed in currentNCBIinfo, check taxon database: ", + paste(missingTaxa, collapse = ", ") + ) + ) + } for (refID in inputTaxa) { # get info for this taxon + if (refID %in% missingTaxa) { + next + } refEntry <- currentNCBIinfo[currentNCBIinfo$ncbiID == refID, ] lastID <- refEntry$parentID inputTaxaInfo <- refEntry