Loading more than 16 annotation packages fails
1
0
Entering edit mode
Tarca, Adi ▴ 570
@tarca-adi-1500
Last seen 12 months ago
United States
Dear all, I have 17 array annotation packages that I want to load and use the information in them. After every package loading (via require) I detach the package. However, I run out of RS-DBI connections. Here is the code: > chips [1] "ag" "ath1121501" "drosgenome1" "drosophila2" "hcg110" "hgfocus" "hgu133a" "hgu133a2" [9] "hgu133b" "hgu133plus2" "hgu95a" "hgu95av2" "hgu95b" "hgu95d" "hgu95e" "hu35ksuba" [17] "hu35ksubb" > for (cip in 1:length(chips)){ + if (require(paste(chips[cip],"db",sep="."),character.only=TRUE)){ + + pac<-paste("package:",chips[cip],".db",sep="") + detach(pos = match(pac, search())) + + } + } Loading required package: ag.db ..... Loading required package: hu35ksubb.db Error in sqliteNewConnection(drv, ...) : RS-DBI driver: (0cannot allocate a new connection -- maximum of 16 connections already opened) Error : .onLoad failed in 'loadNamespace' for 'hu35ksubb.db' Any ideas? Thanks, Adi L. Tarca
Annotation hu35ksubb Annotation hu35ksubb • 951 views
ADD COMMENT
0
Entering edit mode
Seth Falcon ▴ 150
@seth-falcon-2443
Last seen 10.2 years ago
* On 2008-07-28 at 16:29 -0400 Tarca, Adi wrote: > I have 17 array annotation packages that I want to load and use the > information in them. > After every package loading (via require) I detach the package. > However, I run out of RS-DBI connections. > Here is the code: > > > > chips > [1] "ag" "ath1121501" "drosgenome1" "drosophila2" "hcg110" > "hgfocus" "hgu133a" "hgu133a2" > [9] "hgu133b" "hgu133plus2" "hgu95a" "hgu95av2" "hgu95b" > "hgu95d" "hgu95e" "hu35ksuba" > [17] "hu35ksubb" > > for (cip in 1:length(chips)){ > + if (require(paste(chips[cip],"db",sep="."),character.only=TRUE)){ > + > + pac<-paste("package:",chips[cip],".db",sep="") > + detach(pos = match(pac, search())) Try passing unload=TRUE to detach? The following is working for me, although I probably have out of date packages: for (x in 1:50) { require("rae230a.db") detach("package:rae230a.db", unload=TRUE) } Unloading the rae230a.db namespace gives a warning, which is probably another matter: > require("rae230a.db") Loading required package: rae230a.db > detach("package:rae230a.db", unload=TRUE) Warning message: In getPackageName(where) : Created a package name, "2008-07-28 16:52:36", when none found > sessionInfo() R version 2.8.0 Under development (unstable) (--) i386-apple-darwin9.2.2 locale: C attached base packages: [1] tools stats graphics grDevices datasets utils methods [8] base other attached packages: [1] AnnotationDbi_1.1.20 RSQLite_0.6-8 DBI_0.2-4 [4] Biobase_1.17.13 -- Seth Falcon | http://userprimary.net/user/
ADD COMMENT

Login before adding your answer.

Traffic: 772 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6