sortOmicsDataByRow {caOmicsV} | R Documentation

## Sort Omics Data by Row

### Description

Sort omics data by row (genes) in order to get omics data in a specific order, e.g., ordered by p values or by fold changes in expression data. After sorting, the order of row names in omics data will be same as the second argument.

### Usage

        sortOmicsDataByRow(omicsData, geneNames)

### Arguments

`omicsData` | a data frame that holds genomic data such as gene expression, SNV, RNASeq. The first column must be gene names that are same as the second argument except of order.
`geneNames` | character vector, gene names in a given order (such as by p values). Redundant gene names are allowed.

### Value

`omicsData` | copy of the first argument with new row order.

### Author(s)

Henry Zhang

### Examples

        data(RNASeqDemoData)
        geneNames <- as.character(RNASeqDemoData[,1])
        geneNames <- geneNames[order(RNASeqDemoData[,2])]
        expr <- sortOmicsDataByRow(RNASeqDemoData, geneNames)

[Package caOmicsV version 1.16.0 Index]