Last data update: 2014.03.03

R: Create and check mzR objects from netCDF, mzXML, mzData or...
openMSfileR Documentation

Create and check mzR objects from netCDF, mzXML, mzData or mzML files.

Description

The openMSfile constructor will create a new format-specifc mzR object, open 'filename' file and all header information is loaded as a Rcpp module and made accessible through the ramp or pwiz slot of the resulting object.

The openIDfile constructor will create a new format-specifc mzR object, open 'filename' file and all information is loaded as a Rcpp module. The mzid format is supported throught pwiz backend. Only mzIdentML 1.1 is supported.

Usage

 openMSfile(filename, backend=c("Ramp", "pwiz", "netCDF"), verbose = FALSE)

 initializeRamp(object)

 isInitialized(object)

 fileName(object, ...)
 
 openIDfile(filename, verbose = FALSE)

Arguments

filename

Path name of the netCDF, mzData, mzXML or mzML file to read/write.

backend

A character specifiying with backend API to use. Currently 'Ramp', 'netCDF' and 'pwiz' are available.

object

An instantiated mzR object.

verbose

Enable verbose output.

...

Additional arguments, currently ignored.

Author(s)

Steffen Neumann, Laurent Gatto, Qiang Kou

Examples

 library(msdata)
 filepath <- system.file("microtofq", package = "msdata")
 file <- list.files(filepath, pattern="MM14.mzML",
                     full.names=TRUE, recursive = TRUE)
 mz <- openMSfile(file)
 fileName(mz)
 runInfo(mz)
 close(mz)

 ## Not run: 
    ## to use another backend
    mz <- openMSfile(file, backend = "pwiz")
    mz
  
## End(Not run)
  
  file <- system.file("mzid", "Tandem.mzid.gz", package="msdata")
  mzid <- openIDfile(file)
  softwareInfo(mzid)
  enzymes(mzid)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-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.

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(mzR)
Loading required package: Rcpp
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/mzR/openMSfile.Rd_%03d_medium.png", width=480, height=480)
> ### Name: openMSfile
> ### Title: Create and check mzR objects from netCDF, mzXML, mzData or mzML
> ###   files.
> ### Aliases: openMSfile initializeRamp isInitialized fileName openIDfile
> 
> ### ** Examples
> 
>  library(msdata)
>  filepath <- system.file("microtofq", package = "msdata")
>  file <- list.files(filepath, pattern="MM14.mzML",
+                      full.names=TRUE, recursive = TRUE)
>  mz <- openMSfile(file)
>  fileName(mz)
[1] "/home/ddbj/local/lib64/R/library/msdata/microtofq/MM14.mzML"
>  runInfo(mz)
$scanCount
[1] 112

$lowMz
[1] 0

$highMz
[1] 0

$dStartTime
[1] 270.334

$dEndTime
[1] 307.678

$msLevels
[1] 1

>  close(mz)
> 
>  ## Not run: 
> ##D     ## to use another backend
> ##D     mz <- openMSfile(file, backend = "pwiz")
> ##D     mz
> ##D   
> ## End(Not run)
>   
>   file <- system.file("mzid", "Tandem.mzid.gz", package="msdata")
>   mzid <- openIDfile(file)
>   softwareInfo(mzid)
[1] "xtandem x! tandem CYCLONE (2010.06.01.5) "   
[2] "ProteoWizard MzIdentML 3.0.6239 ProteoWizard"
>   enzymes(mzid)
     name nTermGain cTermGain minDistance missedCleavages
1 Trypsin         H        OH           0               1
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>