readQFeatures: QFeatures from tabular data

Description Usage Arguments Value Functions Author(s) See Also Examples

View source: R/QFeatures-constructors.R

Description

Convert tabular data from a spreadsheet or a data.frame into a QFeatures object.

Usage

1
2
3
readQFeatures(table, ecol, fnames, ..., name = NULL)

readSummarizedExperiment(table, ecol, fnames, ...)

Arguments

table

File or object holding the quantitative data. Can be either a character(1) with the path to a text-based spreadsheet (comma-separated values by default, but see ...) or an object that can be coerced to a data.frame. It is advised not to encode characters as factors.

ecol

A numeric indicating the indices of the columns to be used as expression values. Can also be a character indicating the names of the columns. Caution must be taken if the column names are composed of special characters like ( or - that will be converted to a . by the read.csv function. If ecol does not match, the error message will display the column names as seen by the read.csv function.

fnames

An optional character(1) or numeric(1) indicating the column to be used as feature names.

...

Further arguments that can be passed on to read.csv except stringsAsFactors, which is always FALSE.

name

An character(1) to name assay in the QFeatures object. If not set, features is used.

Value

An instance of class QFeatures or SummarizedExperiment.

Functions

Author(s)

Laurent Gatto

See Also

The QFeatures class for an example on how to use readQFeatures and how to further manipulate the resulting data.

Examples

1
2
3
4
5
6
## Load a data.frame with PSM-level data
data(hlpsms)

## Create the QFeatures object
fts2 <- readQFeatures(hlpsms, ecol = 1:10, name = "psms")
fts2

QFeatures documentation built on Nov. 8, 2020, 6:51 p.m.