ropensci / phylotaR

An automated pipeline for retrieving orthologous DNA sequences from GenBank in R
https://docs.ropensci.org/phylotaR
Other
23 stars 9 forks source link

Error in run.R II #13

Closed azizka closed 6 years ago

azizka commented 7 years ago

The cluster.ci_gi.seqs.create function drops the following error

Counting species for taxon 4613 Number of sequences for taxon 4613 : 16929 Too many seqs to blast for taxid 4613 ... retrieving children Error in .children(current.taxon, nodes) : unused argument (nodes)

Reproducible example

#try out to get a molecular alignment using Phylotar

#libraries
#source the phylotaR package
source("blast.R")
source("ci_gi.R")
source("cl.R")
source("clusters.R")
source("db.R")
source("ncbi-remote.R")
source("nodes.R")
source("query-local.R")

#run an analysis follwoing the run.sh script, this is the run.r copied
library(foreach)
library(doMC)

set.seed(111)

options(error=recover)

## Adjustable parameters:
## Maximum number of sequences per species
MODEL.THRESHOLD <<- 3000
## Maximum number of sequences to blast in a single run; if taxon has more subtree sequences
## than that, its children will get clustered
MAX.BLAST.SEQS <<- 10000
## Maximum characters in one sequence
MAX.SEQUENCE.LENGTH <<- 25000
## directory for sequence cache; will be created if does not exist
SEQS.CACHE.DIR <<- "./sequences/"
## Download file ftp://ftp.ncbi.nlm.nih.gov/pub/taxonomy/taxdump.tar.gz,
## unzip and specify directory where file 'nodes.dmp' is located
taxdir <- 'taxdmp'
## Number of processing units
CORES <<- 4

registerDoMC(CORES)

## Do analysis for Felidae family
taxid <- 4613
nodes.create(taxid, taxdir=taxdir, file.name='dbfiles-bromeliaceae-nodes.tsv')

clusters.ci_gi.seqs.create(4613, 'dbfiles-bromeliaceae-nodes.tsv', 
                           files=list(clusters='dbfiles-bromeliaceae-clusters.tsv',
                                      ci_gi='dbfiles-bromeliaceae-ci_gi.tsv',
                                      seqs='dbfiles-bromeliaceae-seqs.tsv'))

sessionInfo

R version 3.4.2 (2017-09-28)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1

Matrix products: default

locale:
[1] LC_COLLATE=English_United Kingdom.1252  LC_CTYPE=English_United Kingdom.1252    LC_MONETARY=English_United Kingdom.1252
[4] LC_NUMERIC=C                            LC_TIME=English_United Kingdom.1252    

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
 [1] foreach_1.4.3         CHNOSZ_1.1.0          XML_3.98-1.9          rentrez_1.1.0         igraph_1.1.2         
 [6] RSQLite_2.0           data.table_1.10.4-3   bindrcpp_0.2          speciesgeocodeR_2.0-8 sp_1.2-5             
[11] forcats_0.2.0         stringr_1.2.0         dplyr_0.7.4           purrr_0.2.4           readr_1.1.1          
[16] tidyr_0.7.2           tibble_1.3.4          ggplot2_2.2.1         tidyverse_1.2.0      

loaded via a namespace (and not attached):
 [1] viridis_0.4.0     httr_1.3.1        bit64_0.9-7       jsonlite_1.5      viridisLite_0.2.0 modelr_0.1.1     
 [7] assertthat_0.2.0  blob_1.1.0        cellranger_1.1.0  yaml_2.1.14       lattice_0.20-35   glue_1.2.0       
[13] digest_0.6.12     rvest_0.3.2       colorspace_1.3-2  picante_1.6-2     Matrix_1.2-11     plyr_1.8.4       
[19] psych_1.7.8       pkgconfig_2.0.1   broom_0.4.2       raster_2.5-8      haven_1.1.0       scales_0.5.0     
[25] mgcv_1.8-20       lazyeval_0.2.1    cli_1.0.0         mnormt_1.5-5      magrittr_1.5      crayon_1.3.4     
[31] readxl_1.0.0      memoise_1.1.0     nlme_3.1-131      MASS_7.3-47       xml2_1.1.1        foreign_0.8-69   
[37] vegan_2.4-4       tools_3.4.2       hms_0.3           geosphere_1.5-7   munsell_0.4.3     cluster_2.0.6    
[43] compiler_3.4.2    rlang_0.1.4       grid_3.4.2        iterators_1.0.8   rstudioapi_0.7    codetools_0.2-15 
[49] gtable_0.2.0      curl_3.0          DBI_0.7           reshape2_1.4.2    R6_2.2.2          gridExtra_2.3    
[55] lubridate_1.7.1   knitr_1.17        rgdal_1.2-15      rgeos_0.3-26      bit_1.1-12        bindr_0.1        
[61] permute_0.9-4     ape_5.0           stringi_1.1.5     parallel_3.4.2    Rcpp_0.12.13