read2MSnSet: Import a file and convert it to an MSnSet object

read2MSnSetR Documentation

Import a file and convert it to an MSnSet object

Description

Imports a file and converts it into an MSnSet object (Gatto et al., 2012).

Usage

read2MSnSet(file, pattern = NULL, colInt = NULL, remove_pattern = FALSE,
  sep = "\t", na.strings = NULL, quote = "", comment.char = "",
  shiny = FALSE, message = NULL, ...)

Arguments

file

The name of a file. For more details about how this argument can be specified, see read.table.

pattern

A character string containing a regular expression that will be matched to the file's header. The columns matching the expression should be the columns containing the peptide intensity values. Defaults to NULL. Ignored if colInt is not NULL.

colInt

A vector of integers indicating the columns containing the peptide intensity values. Defaults to NULL, in which case a valid pattern should be specified.

remove_pattern

A logical indicating whether the expression in "pattern" should be removed from the column names in the resulting MSnSet object. Defaults to FALSE.

sep

A character indicating the field separator character. Values on each line of the file are separated by this character.The Defaults to "\t", indicating a tab-delimited input file.

na.strings

A character vector of strings which are to be interpreted as NA values. Blank fields are also considered to be missing values in logical, integer, numeric and complex fields. Note that the test happens after white space is stripped from the input, so na.strings values may need their own white space stripped in advance. Defaults to NULL.

quote

The set of quoting characters. See scan for the behaviour on quotes embedded in quotes. Quoting is only considered for columns read as character. Defaults to "", where quoting is disabled altogether.

comment.char

A character vector of length one containing a single character or an empty string. Defaults to "", in which case the interpretation of comments is turned off altogether.

shiny

A logical indicating whether this function is being used by a Shiny app. Setting this to TRUE only works when using this function in a Shiny app and allows for dynamic progress bars. Defaults to FALSE.

message

Only used when shiny=TRUE. A single-element character vector: the message to be displayed to the user, or NULL to hide the current message (if any).

...

Further arguments that can be passed on to the read.table-like functions.

Value

An object of class MSnSet.

References

Gatto L, Lilley KS. MSnbase - an R/Bioconductor package for isobaric tagged mass spectrometry data visualization, processing and quantitation. Bioinformatics. 2012 Jan 15;28(2):288-9. https://doi.org/10.1093/bioinformatics/btr645.


ludgergoeminne/MSqRob documentation built on Jan. 11, 2023, 1:32 p.m.