lawremi / rtracklayer

R interface to genome annotation files and the UCSC genome browser
Other
28 stars 17 forks source link

import not working anymore #69

Closed komalsrathi closed 2 years ago

komalsrathi commented 2 years ago

Hi,

I am trying to import a gtf file using the import function. This used to work fine before - not sure which R version or package version I had because I recently got a new laptop.

Code:

library(rtracklayer)
fname <- "ftp://ftp.ebi.ac.uk/pub/databases/gencode/Gencode_human/release_27/gencode.v27.primary_assembly.annotation.gtf.gz"
gencode_gtf <- rtracklayer::import(con = fname)

Error in (function (classes, fdef, mtable)  : 
  unable to find an inherited method for function ‘download.file’ for signature ‘"character"’

Session info:

> sessionInfo()
R version 4.2.0 (2022-04-22)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Monterey 12.3.1

Matrix products: default
LAPACK: /Library/Frameworks/R.framework/Versions/4.2/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

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

loaded via a namespace (and not attached):
  [1] colorspace_2.0-3            rjson_0.2.21               
  [3] ellipsis_0.3.2              dynamicTreeCut_1.63-1      
  [5] htmlTable_2.4.0             XVector_0.36.0             
  [7] GenomicRanges_1.48.0        base64enc_0.1-3            
  [9] rstudioapi_0.13             bit64_4.0.5                
 [11] AnnotationDbi_1.58.0        fansi_1.0.3                
 [13] codetools_0.2-18            splines_4.2.0              
 [15] sparseMatrixStats_1.8.0     doParallel_1.0.17          
 [17] cachem_1.0.6                impute_1.70.0              
 [19] knitr_1.39                  Formula_1.2-4              
 [21] Rsamtools_2.12.0            annotate_1.74.0            
 [23] WGCNA_1.71                  cluster_2.1.3              
 [25] GO.db_3.15.0                png_0.1-7                  
 [27] pheatmap_1.0.12             graph_1.74.0               
 [29] HDF5Array_1.24.1            compiler_4.2.0             
 [31] httr_1.4.3                  backports_1.4.1            
 [33] assertthat_0.2.1            Matrix_1.4-1               
 [35] fastmap_1.1.0               limma_3.52.1               
 [37] cli_3.3.0                   BiocSingular_1.12.0        
 [39] htmltools_0.5.2             tools_4.2.0                
 [41] rsvd_1.0.5                  gtable_0.3.0               
 [43] glue_1.6.2                  GenomeInfoDbData_1.2.8     
 [45] dplyr_1.0.9                 Rcpp_1.0.8.3               
 [47] Biobase_2.56.0              vctrs_0.4.1                
 [49] Biostrings_2.64.0           rhdf5filters_1.8.0         
 [51] preprocessCore_1.58.0       rtracklayer_1.56.0         
 [53] iterators_1.0.14            DelayedMatrixStats_1.18.0  
 [55] xfun_0.31                   fastcluster_1.2.3          
 [57] stringr_1.4.0               beachmat_2.12.0            
 [59] lifecycle_1.0.1             irlba_2.3.5                
 [61] restfulr_0.0.14             XML_3.99-0.9               
 [63] zlibbioc_1.42.0             scales_1.2.0               
 [65] MatrixGenerics_1.8.0        parallel_4.2.0             
 [67] SummarizedExperiment_1.26.1 rhdf5_2.40.0               
 [69] RColorBrewer_1.1-3          yaml_2.3.5                 
 [71] SingleCellExperiment_1.18.0 memoise_2.0.1              
 [73] DGCA_1.0.2                  gridExtra_2.3              
 [75] ggplot2_3.3.6               rpart_4.1.16               
 [77] latticeExtra_0.6-29         stringi_1.7.6              
 [79] RSQLite_2.2.14              GSVA_1.44.1                
 [81] BiocIO_1.6.0                S4Vectors_0.34.0           
 [83] foreach_1.5.2               ScaledMatrix_1.4.0         
 [85] checkmate_2.1.0             BiocGenerics_0.42.0        
 [87] BiocParallel_1.30.2         GenomeInfoDb_1.32.2        
 [89] rlang_1.0.2                 pkgconfig_2.0.3            
 [91] matrixStats_0.62.0          bitops_1.0-7               
 [93] lattice_0.20-45             purrr_0.3.4                
 [95] Rhdf5lib_1.18.2             GenomicAlignments_1.32.0   
 [97] htmlwidgets_1.5.4           bit_4.0.4                  
 [99] tidyselect_1.1.2            GSEABase_1.58.0            
[101] magrittr_2.0.3              R6_2.5.1                   
[103] IRanges_2.30.0              generics_0.1.2             
[105] Hmisc_4.7-0                 DelayedArray_0.22.0        
[107] DBI_1.1.2                   pillar_1.7.0               
[109] foreign_0.8-82              survival_3.3-1             
[111] KEGGREST_1.36.0             RCurl_1.98-1.6             
[113] nnet_7.3-17                 tibble_3.1.7               
[115] crayon_1.5.1                utf8_1.2.2                 
[117] jpeg_0.1-9                  grid_4.2.0                 
[119] data.table_1.14.2           blob_1.2.3                 
[121] digest_0.6.29               xtable_1.8-4               
[123] stats4_4.2.0                munsell_0.5.0  
komalsrathi commented 2 years ago

Closing as this seems to be resolved.