Hi Pierre,

I think I know what units for now. I used units <- c(1:235834) and it
worked.

Thanks,

Ying


On Thu, May 17, 2012 at 3:21 PM, sean nj <[email protected]> wrote:

> Hi Pierre,
>
> Sorry to bother you again.
>
> I am following the Vignette: Creating binary data files containing copy
> number estimates (http://www.aroma-project.org/node/88) and trying to
> create a UGP file. But I am confused with the codes listed:
>
>         units <- c(1,4,7);
>         ugp[units,1] <- 1;
>
>         ugp[units,2] <- c(554268, 736483, 757922);
> I tried to find some information regarding ugp, but had no success. My
> question is what the units <- c(1,4,7)for? What does 1, 4, and 7 mean?
>
> I want to make a ugp file for Agilent UG-CGH-244A chip files I got from
> TCGA-GBM data, which has 235834 probes. When I used units <- c(1,4,7),
>
> > mydata <- read.delim(file.choose())
> > mydata <- as.data.frame(mydata)
> > str(mydata)
> 'data.frame':   235834 obs. of  12 variables:
>  $ unitName
> : Factor w/ 235834 levels "A_14_P100000",..: 12409 103695 103696 41581
> 41582 41583 41584 41585 41586 41587 ...
>  $ unitCount
> : int  1 2 3 4 5 6 7 8 9 10 ...
>  $ Gene_Symbol
> : Factor w/ 16808 levels "","1-Dec","1-Mar",..: 1 1 1 1 1 1 1 1 1 1 ...
>  $ Description
> : Factor w/ 16670 levels "","1-acylglycerol-3-phosphate O-acyltransferase 1
> (lysophosphatidic acid acyltransferase, alpha)",..: 1 1 1 1 1 1 1 1 1 1 ...
>  $ Chromosome
> : int  1 1 1 1 1 1 1 1 1 1 ...
>  $ chr_start
> : int  604268 604287 689581 786483 792533 796956 807922 819590 834458
> 842413 ...
>  $ chr_end
> : int  604327 604346 689640 786542 792586 797005 807966 819649 834517
> 842458 ...
>  $ Cytoband
> : Factor w/ 259 levels "","hs|p11","hs|p11.1",..: 97 97 97 97 97 97 97 97
> 97 97 ...
>  $
> Reporter..genbank..Comment.OMOSOMAL_LOCATION..Comment.ACCESSION_STRING.:
> Factor w/ 235649 levels ":::","::NC_000001.8[000786483..000786542]:",..:
> 85381 85382 91604 2 3 4 101218 101217 87259 5 ...
>  $ Chr
> : int  1 1 1 1 1 1 1 1 1 1 ...
>  $ Start_GRCH37
> : int  564405 564424 649718 746620 752670 757093 768059 779727 794595
> 802550 ...
>  $ End_GRCH37
> : int  564464 564483 649777 746679 752723 757142 768103 779786 794654
> 802595 ...
> > units <- c(1,4,7)
> > ugp[units,1] <- mydata$Chromosome
> > ugp[units,2] <- mydata$chr_start
> > print(ugp[units,])
>   chromosome position
> 1          1   604268
> 2          1   604287
> 3          1   689581
> Here I only got 3 probes, instead of 235834.
>
> > print(ugp[1:4,])
>   chromosome position
> 1          1   604268
> 2         NA       NA
> 3         NA       NA
> 4          1   604287
> >
>
> Here I am not sure where the NAs are from.
>
> Any suggestion?
>
> Thanks a lot for the help!
>
> Ying
>
> On Wednesday, May 16, 2012 4:19:31 PM UTC-4, sean nj wrote:
>
>> Hi Pierre,
>>
>> I figured out what's wrong. I did not set the object unitNames.
>>
>> After I ran
>>
>>       > unitNames <- getUnitNames(unf)
>>       > units <- indexOf(unf,names=unitNames)
>>
>> it works now.
>>
>> Thanks,
>>
>>
>> Ying
>>
>>
>>
>>
>> On Wed, May 16, 2012 at 3:44 PM, Pierre Neuvial <[email protected]
>> > wrote:
>>
>>> Hi,
>>>
>>> On Wed, May 16, 2012 at 9:05 PM, sean nj <[email protected]> wrote:
>>> >
>>> > Hi,
>>> >
>>> > I did get rid of the error message when I ran :
>>> >
>>> >                             > unf <- TextUnitNamesFile$byChipType(**
>>> chipType)
>>> >
>>> > I got this done by loading the aroma.affymetrix package, in addition
>>> to aroma.core.
>>> >
>>> > But now I got another error message when I followed Henrik's code at
>>> http://aroma-project.org/node/**88 <http://aroma-project.org/node/88>
>>> >
>>> > I was trying to creating data files containing log2 CN ratios.
>>> Everything was fine until I ran
>>> >
>>> > > units <- indexOf(unf, unitNames)
>>> > Error in indexOf.UnitNamesFile(unf, unitNames) :
>>> > [2012-05-16 14:53:18] Exception: If specified, argument 'pattern' must
>>> be a single string. Did you mean to use argument 'names'?
>>> >   at #02. indexOf.UnitNamesFile(unf, unitNames)
>>> >           - indexOf.UnitNamesFile() is in environment 'aroma.core'
>>> >   at #01. indexOf(unf, unitNames)
>>> >           - indexOf() is in environment 'R.filesets'
>>> > >
>>> >
>>>
>>> From the error message (pretty explicit) it looks like you should  have
>>> done
>>>
>>> units <- indexOf(unf, names=unitNames)
>>>
>>> instead of
>>>
>>> units <- indexOf(unf, unitNames)
>>>
>>> That's what you do below.
>>>
>>> Cheers,
>>>
>>> Pierre
>>>
>>> > The command ran successfully when I tried to get units for certain
>>> probes
>>> >
>>> > > units <- indexOf(unf, names=c("A_16_P15025341","A_**16_P00013121")
>>> > + )
>>> > > units
>>> > [1] 1006 1019
>>> > >
>>> > I tried  > ?indexOf.UnitNamesFile()   and here is what I got:
>>> >
>>> >     indexOf(this, pattern=NULL, names=NULL, ...)
>>> >
>>> >     Arguments
>>> >
>>> >  pattern    A pattern to be used for identifying unit names of
>>> interest. If NULL, no regular expression matching is done.
>>> >
>>> >
>>> >
>>> > names    Names to be match exactly to the unit names.
>>> >
>>> > ...            Not used.
>>> >
>>> >
>>> > What did I do wrong?
>>> >
>>> > Thanks a lot for the help!
>>> >
>>> > Ying
>>> >
>>> > > sessionInfo()
>>> > R version 2.15.0 (2012-03-30)
>>> > Platform: x86_64-pc-mingw32/x64 (64-bit)
>>> > locale:
>>> > [1] LC_COLLATE=English_United States.1252  LC_CTYPE=English_United
>>> States.1252
>>> > [3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
>>> > [5] LC_TIME=English_United States.1252
>>> > attached base packages:
>>> > [1] stats     graphics  grDevices utils     datasets  methods   base
>>> > other attached packages:
>>> >  [1] aroma.affymetrix_2.5.0 affxparser_1.28.0
>>> aroma.apd_0.2.2        R.huge_0.3.0
>>> >  [5] aroma.core_2.5.0       aroma.light_1.24.0
>>> matrixStats_0.5.0      R.rsp_0.7.5
>>> >  [9] R.filesets_1.1.5       digest_0.5.2
>>> R.cache_0.6.2          R.utils_1.12.1
>>> > [13] R.oo_1.9.3             R.methodsS3_1.2.2
>>> > loaded via a namespace (and not attached):
>>> > [1] tools_2.15.0
>>> > >
>>> >
>>> >
>>> > On Tue, May 15, 2012 at 12:38 PM, sean nj <[email protected]> wrote:
>>> >>
>>> >> Hi guys,
>>> >>
>>> >> I was following the Vignette: Creating binary data files containing
>>> copy number estimates and trying to work on agilent HG-CGH-244A chip. I
>>> downloaded and unzipped the .gz of the 
>>> HG-CGH-244A,TCGA,HB20080512,**unitNames.txt
>>> and HG-CGH-244A,TCGA,HB20080512.**ugp and put them in H:\Aroma_Analysis\
>>> **annotationData\chipTypes\HG-**CGH-244A folder. Then I tried to run
>>> the same code on the vignette and got the error right away (please see end
>>> of this email). Did I do something wrong?
>>> >>
>>> >> I have one more question regarding "Creating data files containing
>>> log2 CN ratios" with HG-CGH-244A chip. The data I have are level 2 files
>>> from TCGA. There is one txt file for each sample (not the original .asb
>>> file) and its format is like:
>>> >>
>>> >>
>>> >> Hybridization REF MSK_00001_251469322729_S01_**CGH-v4_91
>>> >>
>>> >> Composite Element REF normalizedLog2Ratio
>>> >>
>>> >> A_14_P112718 0.135431541355747
>>> >>
>>> >> A_16_P15000916 0.441719513563848
>>> >>
>>> >> A_16_P15001074 0.227252175271962
>>> >>
>>> >> A_16_P00000012 0.231158251618718
>>> >>
>>> >> A_16_P00000014 -0.0623833233443793
>>> >>
>>> >> ..............................**...........................
>>> >>
>>> >> ..............................**............................
>>> >>
>>> >> My first question is, does this kind data file work?
>>> >>
>>> >> My second question is, do I need to create a folder rawCnData as
>>> mentioned in the vignette (Pathname: rawCnData/MyDataSet,tagA,tagB/**
>>> HG-CGH-244A/SampleA,tagA,tagB,**log2ratio,total.asb)?  I also have the
>>> rawData folder which holds affy snp6 and expression data.
>>> >>
>>> >>
>>> >>
>>> >> Thanks a lot for the help!
>>> >>
>>> >>
>>> >>
>>> >> Ying
>>> >>
>>> >> > library(aroma.core)
>>> >> > chipType <- "HG-CGH-244A"
>>> >> > unf <- TextUnitNamesFile$byChipType(**chipType)
>>> >> Error in method(static, ...) :
>>> >> [2012-05-15 12:12:26] Exception: Failed to create TextUnitNamesFile
>>> object. Could to locate an annotation data file for chip type 'HG-CGH-244A'
>>> (without requiring any tags) and with filename extension 'names' (this may
>>> not be the correct extension as it was guessed from the class name
>>> 'TextUnitNamesFile').
>>> >>
>>> >>   at #02. method(static, ...)
>>> >>           - method() is in environment 'aroma.core'
>>> >>   at #01. TextUnitNamesFile$byChipType(**chipType)
>>> >>           - TextUnitNamesFile$byChipType() is local of the calling
>>> function
>>> >> > sessionInfo()
>>> >> R version 2.15.0 (2012-03-30)
>>> >> Platform: x86_64-pc-mingw32/x64 (64-bit)
>>> >> locale:
>>> >> [1] LC_COLLATE=English_United States.1252  LC_CTYPE=English_United
>>> States.1252    LC_MONETARY=English_United States.1252 LC_NUMERIC=C
>>> >> [5] LC_TIME=English_United States.1252
>>> >> attached base packages:
>>> >> [1] stats     graphics  grDevices utils     datasets  methods   base
>>> >> other attached packages:
>>> >>  [1] aroma.core_2.5.0   aroma.light_1.24.0 matrixStats_0.5.0
>>> R.rsp_0.7.5        R.filesets_1.1.5   digest_0.5.2       R.cache_0.6.2
>>> R.utils_1.12.1
>>> >>  [9] R.oo_1.9.3         R.methodsS3_1.2.2
>>> >> >
>>> >>
>>> >>
>>> >>
>>> >> --
>>> >> When reporting problems on aroma.affymetrix, make sure 1) to run the
>>> latest version of the package, 2) to report the output of sessionInfo() and
>>> traceback(), and 3) to post a complete code example.
>>> >>
>>> >>
>>> >> You received this message because you are subscribed to the Google
>>> Groups "aroma.affymetrix" group with website
>>> http://www.aroma-project.org/.
>>> >> To post to this group, send email to aroma-affymetrix@googlegroups.**
>>> com <[email protected]>
>>> >> To unsubscribe and other options, go to http://www.aroma-project.org/
>>> **forum/ <http://www.aroma-project.org/forum/>
>>> >
>>> >
>>> > --
>>> > When reporting problems on aroma.affymetrix, make sure 1) to run the
>>> latest version of the package, 2) to report the output of sessionInfo() and
>>> traceback(), and 3) to post a complete code example.
>>> >
>>> >
>>> > You received this message because you are subscribed to the Google
>>> Groups "aroma.affymetrix" group with website
>>> http://www.aroma-project.org/.
>>> > To post to this group, send email to aroma-affymetrix@googlegroups.**
>>> com <[email protected]>
>>> > To unsubscribe and other options, go to http://www.aroma-project.org/*
>>> *forum/ <http://www.aroma-project.org/forum/>
>>>
>>> --
>>> When reporting problems on aroma.affymetrix, make sure 1) to run the
>>> latest version of the package, 2) to report the output of sessionInfo() and
>>> traceback(), and 3) to post a complete code example.
>>>
>>>
>>> You received this message because you are subscribed to the Google
>>> Groups "aroma.affymetrix" group with website
>>> http://www.aroma-project.org/.
>>> To post to this group, send email to 
>>> aroma-affymetrix@googlegroups.**com<[email protected]>
>>> To unsubscribe and other options, go to http://www.aroma-project.org/**
>>> forum/ <http://www.aroma-project.org/forum/>
>>>
>>
>>  --
> When reporting problems on aroma.affymetrix, make sure 1) to run the
> latest version of the package, 2) to report the output of sessionInfo() and
> traceback(), and 3) to post a complete code example.
>
>
> You received this message because you are subscribed to the Google Groups
> "aroma.affymetrix" group with website http://www.aroma-project.org/.
> To post to this group, send email to [email protected]
> To unsubscribe and other options, go to
> http://www.aroma-project.org/forum/
>

-- 
When reporting problems on aroma.affymetrix, make sure 1) to run the latest 
version of the package, 2) to report the output of sessionInfo() and 
traceback(), and 3) to post a complete code example.


You received this message because you are subscribed to the Google Groups 
"aroma.affymetrix" group with website http://www.aroma-project.org/.
To post to this group, send email to [email protected]
To unsubscribe and other options, go to http://www.aroma-project.org/forum/

Reply via email to