Skip to main content
Topic: 0 values for first imported tsv file (Read 12011 times) previous topic - next topic

0 values for first imported tsv file

Hello All,
I have problem with reading (?)  tsv files by metaXCMS package in R. Here is the situation:
The pairwise comparison in xcms results with 5 tsv files. Then tsv  files, let’s call them : 1.tsv; 2.tsv; 3.tsv; 4.tsv and 5.tsv are imported to metaXCMS.  After choosing control and applying filters common features are found.  Venn Diagram shows numbers in all circles but first one (in this case 1.tsv). Exported all features table shows values in all rows and columns except the columns from file 1 (numbers are replaced with NA).  When the order of imported files is changed,  let’s say: 2,3,4,5,1 then situation as describe above occurs, however, now the zero values/NA are put in place of file 2 and for file 1 (which was imported as last one) appropriated values are shown. I use 32 bit 2.15.1 R version and 0.1.19 metaXCMS version.
I would greatly appreciate comments and suggestions on this issue,
Best,
Monika

Re: 0 values for first imported tsv file

Reply #1
If you can send me the .tsv files together with the parameters you used then I'll look into it.
I also need to know which XCMS version is installed.
Code: [Select]
library(xcms)
sessionInfo()

Ralf

Re: 0 values for first imported tsv file

Reply #2
Hello Ralf,
Thank you very much for looking up this problem. Attached please find information about xcms version and parameters I used to process the data. How can I send you .tsv files? Here the max. allowed size is 256kB and my files are approximately 2.3MB each.

Best,
Monika

Re: 0 values for first imported tsv file

Reply #3
Can you try something for me ?
Please install an older XCMS version and see if you get the same result.

Thanks,
Ralf

Re: 0 values for first imported tsv file

Reply #4
Hey Ralf,

Good news. I installed xcms_1.30.3 version and processed the data again. It worked, I don't get zero/NA values in metaXCMS output:) Could you explain what caused the problem? However, there is additional info (warning messages) after diffreport function is executed.

Warning messages:
1: sd(<matrix>) is deprecated.
 Use apply(*, 2, sd) instead.
2: sd(<matrix>) is deprecated.
 Use apply(*, 2, sd) instead.
3: In data.row.names(row.names, rowsi, i) :
  some row.names duplicated:
76,266,339,394,419,428,446,463,492,505,506,669,710,731,732,749,766,875,885,923,929,932,943,1061,1075,1208,1309,1456,1548,1951,1999,2145,2595,2686,2933,3822,5018,6772,7992 --> row.names NOT used

Actually, I have seen the message number 3 before, I am not sure how I should interpret that. I understand whatever is duplicated is automatically removed from final results table and original value stays, ergo, I do not lose any data, is that right? Could you please explain what exactly got duplicated? Should I be concern about these warnings?

Best, Monika

Re: 0 values for first imported tsv file

Reply #5
You can ignore these warnings.

There was a change in the implementation of group.nearest which does not seem to be compatible with metaXCMS or at least gives unexpected results.

Please use the older XCMS with metaXCMS for now until I have figured out what exactly causes the problem.
(You can still use the newest XCMS version for XCMS processing, e.g. with different R versions installed side by side.)

Ralf

Re: 0 values for first imported tsv file

Reply #6
metaXCMS 0.1.20 was released today. metaXCMS should now work properly with all XCMS versions.

Re: 0 values for first imported tsv file

Reply #7
Hey Ralf,

It seems there is a problem again. After you suggested installing older version of xcms I was able to process my samples. However recently, my colleague was having some issues and asked me to analyze his data and I encounter the same problem as before (no common features, first file loaded shows "zero" features on Venn diagram). I tried on my old files (which I processed successfully before) and the problem still exists.(?!) How is it possible that it worked before and now I am stuck with the same issue again? I have not changed  anything (R, or xcms version)! just added more packages....

Today I tried to install metaXCMS 0.1.20 but I got error:
Error in read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open the connection
In addition: Warning message:
In read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open compressed file 'metaXCMS_0.1.20 (1)/DESCRIPTION', probable reason 'No such file or directory'

We would appreciate if you could take a look again and find out what causes the problem this time.
Regards,
Monika

Re: 0 values for first imported tsv file

Reply #8
Can you paste the following into your R session and post the output ?
Code: [Select]
library(metaXCMS)
sessionInfo()

Re: 0 values for first imported tsv file

Reply #9
Hey Ralf,

Thank you very much for your reply. Here is the session info + R version info you requested.

All Best,
Monika

R version 2.15.1 (2012-06-22) -- "Roasted Marshmallows"
Copyright (C) 2012 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: i386-pc-mingw32/i386 (32-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(metaXCMS)
Loading required package: cairoDevice
Loading required package: RGtk2
Loading required package: Biobase
Loading required package: BiocGenerics

Attaching package: ‘BiocGenerics’

The following object(s) are masked from ‘package:stats’:

    xtabs

The following object(s) are masked from ‘package:base’:

    anyDuplicated, cbind, colnames, duplicated, eval, Filter, Find,
    get, intersect, lapply, Map, mapply, mget, order, paste, pmax,
    pmax.int, pmin, pmin.int, Position, rbind, Reduce, rep.int,
    rownames, sapply, setdiff, table, tapply, union, unique

Welcome to Bioconductor

    Vignettes contain introductory material; view with
    'browseVignettes()'. To cite Bioconductor, see
    'citation("Biobase")', and for packages 'citation("pkgname")'.

Loading required package: xcms
Loading required package: mzR
Loading required package: Rcpp

Attaching package: ‘xcms’

The following object(s) are masked from ‘package:Biobase’:

    phenoData, phenoData<-

Loading required package: gstat
Loading required package: sp
Loading required package: RANN
Warning messages:
1: package ‘mzR’ was built under R version 2.15.3
2: package ‘Rcpp’ was built under R version 2.15.3
3: In fun(libname, pkgname) :
  mzR has been built against a different Rcpp version
 than is installed on your system. This might lead to errors
 when loading mzR. If you encounter such issues, please send
 a report, including the output of sessionInfo() to the Bioc
 mailing list -- http://www.bioconductor.org/help/mailing-list.
4: package ‘gstat’ was built under R version 2.15.3
5: package ‘sp’ was built under R version 2.15.3
6: package ‘RANN’ was built under R version 2.15.2
> sessionInfo()
R version 2.15.1 (2012-06-22)
Platform: i386-pc-mingw32/i386 (32-bit)

locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252 
[3] LC_MONETARY=English_United States.1252
[4] 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] metaXCMS_0.1.19    RANN_2.2.1        gstat_1.0-16      sp_1.0-11       
 [5] xcms_1.34.0        mzR_1.4.7          Rcpp_0.10.4        Biobase_2.18.0   
 [9] BiocGenerics_0.4.0 RGtk2_2.20.25      cairoDevice_2.19 

loaded via a namespace (and not attached):
[1] codetools_0.2-8  grid_2.15.1      intervals_0.14.0 lattice_0.20-6 
[5] spacetime_1.0-5  xts_0.9-5        zoo_1.7-10     
>

Re: 0 values for first imported tsv file

Reply #10
Please install metaXCMS 0.1.20.  That should fix the problem.

Re: 0 values for first imported tsv file

Reply #11
Hello Ralf,

I did help. Thank you.

Unfortunately, we have another problem with meta XCMS on one of our computers. It is somehow similar (?). In short, when we load tsv files metaXCMS "remembers" the very first files we ever loaded. Here is the situation: say, the first set of data we ever analyzed on this computer using xcms/metaXCMS packages was called A.tsv, B.tsv, C.tsv. and D.tsv. A.tsv contained data named control1, control2, control3 and stress1, stress2, stress3. There was no problem with analysis. All files were removed after analysis. Recently we wanted to analyze another set of data, now it would be: F.tsv, G.tsv, H.tsv and I.tsv. All of the new tsv files do NOT contain data set named control or stress. Now, when we load them into metaXCMS, we see in the first line of metaxcms window: F.tsv however when we click on the file the names are not as in the F.tsv file: they are still from our first analysis from A.tsv (always appearing along with the first file loaded, always from A.tsv, never from other ones). Interestingly, in R session window we have confirmation F.tsv was loaded with the proper content. We can proceed with analysis but at the end Venn diagram show zero values for first file and common and give an error:missing value where TRUE/FALSE needed.

We uninstalled older (2.15.1) and installed updated R version (2.15.3) and version of metaXCMS_0.1.20 but it did not help to clear the issue. Additionally, now there is an warning message in R session:
During startup - Warning messages:
1: In fun(libname, pkgname) :
  mzR has been built against a different Rcpp version
 than is installed on your system. This might lead to errors
 when loading mzR. If you encounter such issues, please send
 a report, including the output of sessionInfo() to the Bioc
 mailing list -- http://www.bioconductor.org/help/mailing-list.
2: Class "C++Object" is defined (with package slot ‘Rcpp’) but no metadata object found to revise subclass information---not exported?  Making a copy in package ‘.GlobalEnv’

It would be wonderful if we could use this computer again for analysis,
Regards, Monika

P.S.
Should I describe this problem in new post?

Re: 0 values for first imported tsv file

Reply #12
1. It looks like R is restoring a previoulsy saved workspace. Look for a file called ".RData" in your home folder and delete it.

2. you might want to update or reinstall using biocLite() both your mzR and Rcpp package.

Re: 0 values for first imported tsv file

Reply #13
Ralf,

I removed RData files, then installed R and now everything works as before. Thank you for the advice:)

All Best
Monika