[BioC] Importing CDF file for custom array using makecdfenv

James W. MacDonald jmacdon at med.umich.edu
Thu Nov 9 00:22:58 CET 2006


Hi Jenny,

Jenny Drnevich wrote:
> Hi Jim & others,
> 
> I'm at my wit's end - I really cannot figure out anything I am doing wrong 
> in trying to create an environment for a custom Affy array.  It seems I'm 
> having the same problem as in this thread, but the solution Jim suggested 
> isn't working. I've followed the makecdfenv vignette, sections 3 and 4 (I'm 
> following the advice to skip trying to make a package on a PC, for now). 
> Here's what I've tried:
> 
> 
> R version 2.4.0 (2006-10-03)
> Copyright (C) 2006 The R Foundation for Statistical Computing
> ISBN 3-900051-07-0
> #deleting most of intro
> 
>  > setwd("C:/Statistics/Clayton")
> 
>  > source("http://bioconductor.org/biocLite.R")
> 
>  > biocLite("makecdfenv")
> 
> Running getBioC version 0.1.8 with R version 2.4.0
> Running biocinstall version 1.9.9 with R version 2.4.0
> Your version of R requires version 1.9 of Bioconductor.
> trying URL 
> 'http://bioconductor.org/packages/1.9/bioc/bin/windows/contrib/2.4/makecdfenv_1.12.0.zip'
> Content type 'application/zip' length 3307506 bytes
> opened URL
> downloaded 3229Kb
> 
> package 'makecdfenv' successfully unpacked and MD5 sums checked
> 
> The downloaded packages are in
>          C:\Documents and Settings\drnevich\Local 
> Settings\Temp\RtmpCw5Rqb\downloaded_packages
> updating HTML package descriptions
> 
>  > library(makecdfenv)
> 
>  > cleancdfname(whatcdf("p0601_51.CEL"))
> 
> Error in .Call("ReadHeader", filename, compress, PACKAGE = "affy") :
>          C symbol name "ReadHeader" not in DLL for package "affy"

That's an odd one. The error here is because 'ReadHeader' isn't in affy 
anymore, it's in affyio. I was positive these had all been changed. I 
will get this fixed tomorrow, and into the release repository.


> 
> 
> I HOPE all the trouble I'm having below is related to this, and not to me! 
> Because the 'whatcdf' isn't working, I tried to get the cdf name from an 
> AffyBatch object:
> 
>  > raw <- ReadAffy()
> 
>  > raw at cdfName
> [1] "lund-zfa530237N"

Note here what the cdfname is. The affy package will look for this 
*exact* name when looking for the environment. Below, you call it 
something else:

 > lundzfa530237n <- make.cdf.env("lund-zfa530237N.cdf")

If you name it lund-zfa530237N, then everything should be copacetic.

I know this is a PITA. Seth looked at making the naming consistent 
around the time I wrote the email you quote below, and for some reason 
(I forget now what it was) fixing it was way more difficult than one 
might think it would be, especially considering that it is not very 
common to use an unpackaged environment.

Have you considered making a cdf package? Using an env is OK, but it 
isn't as persistent as a package would be (plus you will automatically 
get the correct name using make.cdf.package()).


HTH,

Jim


> 
>  > cleancdfname(raw at cdfName)  # the makecdf vignette says 'getCdfInfo' will 
> look for an environment by this name for the AffyBatch
> [1] "lundzfa530237ncdf"
> 
>  > lundzfa530237ncdf <- make.cdf.env("lund-zfa530237N.cdf")
> Reading CDF file.
> Creating CDF environment
> Wait for about 231 
> dots...............................................................................................................................................................................................................................
> 
>  > length(ls(lundzfa530237ncdf))  #from the help file of 'make.cdf.env", so 
> I think it's been created properly...
> [1] 23136
> 
> # ...but...
>  > raw
> Error in getCdfInfo(object) : Could not obtain CDF environment, problems 
> encountered:
> Specified environment does not contain lund-zfa530237N
> Library - package lundzfa530237ncdf not installed
> Data for package affy did not contain lundzfa530237ncdf
> Bioconductor - lundzfa530237ncdf not available
> AffyBatch object
> size of arrays=754x754 features (53306 kb)
> cdf=lund-zfa530237N (??? affyids)
> number of samples=12
> Error in getCdfInfo(object) : Could not obtain CDF environment, problems 
> encountered:
> Specified environment does not contain lund-zfa530237N
> Library - package lundzfa530237ncdf not installed
> Data for package affy did not contain lundzfa530237ncdf
> Bioconductor - lundzfa530237ncdf not available
> In addition: Warning message:
> missing cdf environment ! in: show(<S4 object of class "AffyBatch">)
> 
> I searched the archives and found this thread from Jim about the seemingly 
> same error:
> 
>  >> I do not get any errors, but when I try to look at the affybatch object
>  >> get the following message:
>  >>
>  >> Error in getCdfInfo(object) : Could not obtain CDF environment, problems
>  >> encountered:
>  >> specified environment does not contain XXX Library - package XXXcdf not
>  >> installed Data for package affy did not contain XXXcdf Bioconductor -
>  >> XXXcdf not available AffyBatch object size of arrays=291x291 features
>  >> (15887 kb) cdf=XXX (??? affyids) number of samples=24 Error in
>  >> getCdfInfo(object) : Could not obtain CDF environment, problems
>  >> encountered:
>  >> Specified environment does not contain XXX
>  >
>  >This line is a hint, although rather oblique. When the affy package
>  >looks for an environment in the current .GlobalEnv, it expects it to be
>  >named XXX, so if you use make.cdf.env, you should name it XXX.
> 
> OK, so this is contrary to what it says in the vignette, but I try it anyway:
> 
>  > rm(lundzfa530237ncdf)
>  > lundzfa530237n <- make.cdf.env("lund-zfa530237N.cdf")
> Reading CDF file.
> Creating CDF environment
> Wait for about 231 
> dots....................................................................................................................................................................................................................................................
> 
> But still no luck!
> 
>  > raw
> Error in getCdfInfo(object) : Could not obtain CDF environment, problems 
> encountered:
> Specified environment does not contain lund-zfa530237N
> Library - package lundzfa530237ncdf not installed
> Data for package affy did not contain lundzfa530237ncdf
> Bioconductor - lundzfa530237ncdf not available
> AffyBatch object
> size of arrays=754x754 features (53306 kb)
> cdf=lund-zfa530237N (??? affyids)
> number of samples=12
> Error in getCdfInfo(object) : Could not obtain CDF environment, problems 
> encountered:
> Specified environment does not contain lund-zfa530237N
> Library - package lundzfa530237ncdf not installed
> Data for package affy did not contain lundzfa530237ncdf
> Bioconductor - lundzfa530237ncdf not available
> In addition: Warning message:
> missing cdf environment ! in: show(<S4 object of class "AffyBatch">)
> 
> Am I doing anything wrong? I can't figure out what it could be for the life 
> of me!!! Contents of workspace and sessionInfo below.
> 
> Thanks,
> Jenny
> 
> 
> 
>  > ls()
>   [1] "biocinstall"               "biocinstall.affyPkgs"
>   [3] "biocinstall.allPkgs"       "biocinstall.defaultPkgs"
>   [5] "biocinstall.graphPkgs"     "biocinstall.litePkgs"
>   [7] "biocinstall.monographPkgs" "biocLite"
>   [9] "lundzfa530237n"                "raw"
> 
>  > sessionInfo()
> R version 2.4.0 (2006-10-03)
> i386-pc-mingw32
> 
> locale:
> LC_COLLATE=English_United States.1252;LC_CTYPE=English_United 
> States.1252;LC_MONETARY=English_United 
> States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252
> 
> attached base packages:
> [1] "splines"   "tools"     "methods"   "stats"     "graphics"  "grDevices"
> [7] "utils"     "datasets"  "base"
> 
> other attached packages:
>     makecdfenv  affyQCReport    simpleaffy         made4 scatterplot3d
>       "1.12.0"      "1.12.0"       "2.8.0"       "1.8.0"      "0.3-24"
>           ade4       affyPLM         gcrma   matchprobes      affydata
>        "1.4-2"      "1.10.0"       "2.6.0"       "1.6.0"      "1.10.0"
> affycoretools       biomaRt         RCurl           XML       GOstats
>        "1.6.0"       "1.8.0"       "0.7-0"     "0.99-93"       "2.0.0"
>       Category    genefilter      survival          KEGG          RBGL
>        "2.0.0"      "1.12.0"        "2.29"      "1.14.0"      "1.10.0"
>       annotate            GO         graph         limma          affy
>       "1.12.0"      "1.14.0"      "1.12.0"       "2.9.1"      "1.12.0"
>         affyio       Biobase       RWinEdt
>        "1.2.0"      "1.12.2"       "1.7-5"
>  >
> 
> 
> 
> 
>>>I do not get any errors, but when I try to look at the affybatch object
>>>I get the following message:
>>>
>>>Error in getCdfInfo(object) : Could not obtain CDF environment, problems
>>>encountered:
>>>Specified environment does not contain XXX Library - package XXXcdf not
>>>installed Data for package affy did not contain XXXcdf Bioconductor -
>>>XXXcdf not available AffyBatch object size of arrays=291x291 features
>>>(15887 kb) cdf=XXX (??? affyids) number of samples=24 Error in
>>>getCdfInfo(object) : Could not obtain CDF environment, problems
>>>encountered:
>>>Specified environment does not contain XXX
>>
>>This line is a hint, although rather oblique. When the affy package
>>looks for an environment in the current .GlobalEnv, it expects it to be
>>named XXX, so if you use make.cdf.env, you should name it XXX. However,
>>if it looks for a package, it has to be named xxxcdf. The best bet is to
>>allow make.cdf.package to do the package naming itself, because it will
>>be 100% correct.
>>
>>
>>>I have tried putting the CDF file (created by BioC) in the R libraries
>>>folder with other libraries, but no luck.
>>
>>Nope. You have to install. This would have worked for maybe R-1.7.0 or
>>so, but modern versions of R require you to install the right way.
>>
>>HTH,
>>
>>Jim
>>
>>
>>>In the makecdfenv vignette it says to "open a terminal with an operating
>>>system shell and write R CMD INSTALL XXXcdf", but I don't know how to do
>>>this on windows.
>>>
>>>Any suggestions would be greatly appreciated!
>>>
>>>Ann
>>>
>>>_______________________________________________
>>>Bioconductor mailing list
>>>Bioconductor at stat.math.ethz.ch
>>>https://stat.ethz.ch/mailman/listinfo/bioconductor
>>>Search the archives:
>>>http://news.gmane.org/gmane.science.biology.informatics.conductor
>>>
>>>--------------------------------------------------------
>>>
>>>
>>>This email is confidential and intended solely for the use o...{{dropped}}
>>>
>>>_______________________________________________
>>>Bioconductor mailing list
>>>Bioconductor at stat.math.ethz.ch
>>>https://stat.ethz.ch/mailman/listinfo/bioconductor
>>>Search the archives: 
>>
>>http://news.gmane.org/gmane.science.biology.informatics.conductor
>>
>>
>>--
>>James W. MacDonald, M.S.
>>Biostatistician
>>Affymetrix and cDNA Microarray Core
>>University of Michigan Cancer Center
>>1500 E. Medical Center Drive
>>7410 CCGC
>>Ann Arbor MI 48109
>>734-647-5623
>>
>>
>>**********************************************************
>>Electronic Mail is not secure, may not be read every day, and should not 
>>be used for urgent or sensitive issues.
>>
>>_______________________________________________
>>Bioconductor mailing list
>>Bioconductor at stat.math.ethz.ch
>>https://stat.ethz.ch/mailman/listinfo/bioconductor
>>Search the archives: 
>>http://news.gmane.org/gmane.science.biology.informatics.conductor
> 
> 
> Jenny Drnevich, Ph.D.
> 
> Functional Genomics Bioinformatics Specialist
> W.M. Keck Center for Comparative and Functional Genomics
> Roy J. Carver Biotechnology Center
> University of Illinois, Urbana-Champaign
> 
> 330 ERML
> 1201 W. Gregory Dr.
> Urbana, IL 61801
> USA
> 
> ph: 217-244-7355
> fax: 217-265-5066
> e-mail: drnevich at uiuc.edu
> 
> _______________________________________________
> Bioconductor mailing list
> Bioconductor at stat.math.ethz.ch
> https://stat.ethz.ch/mailman/listinfo/bioconductor
> Search the archives: http://news.gmane.org/gmane.science.biology.informatics.conductor


-- 
James W. MacDonald
University of Michigan
Affymetrix and cDNA Microarray Core
1500 E Medical Center Drive
Ann Arbor MI 48109
734-647-5623



**********************************************************
Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues.



More information about the Bioconductor mailing list