PhosphoExperiment-operate.Rd
These are methods for combining or subsetting for
PhosphoExperiment
object. This provides some convenience for users.
# S4 method for class 'PhosphoExperiment,ANY,ANY,ANY'
x[i, j, drop = TRUE]
# S4 method for class 'PhosphoExperiment,ANY,ANY,ANY'
x[i, j, ...] <- value
# S4 method for class 'PhosphoExperiment'
rbind(..., deparse.level = 1)
# S4 method for class 'PhosphoExperiment'
cbind(..., deparse.level = 1)
A PhosphoExperiment
object
For [,PhosphoExperiment
, [,PhosphoExperiment<-, i, j
are subscripts that can act to subset the rows of x
For [,PhosphoExperiment
, [,PhosphoExperiment<-, i, j
are subscripts that can act to subset the columns of x
A logical(1)
, ignored by these methods
In cbind
or rbind
, a PhosphoExperiment
objects
An object of a class specified in the S4 method signature.
See ?base::cbind
for a description
of this argument.
In the following code snippets, ppe1
and ppe2
is a
PhosphoExperiment
object with matching colData
.
ppe3
and ppe4
is a PhosphoExperiment
object with
matching rowData
.
rbind(ppe1, ppe2)
:Combine row-wise
cbind(ppe3, ppe4)
:Combine column-wise
method rbind
, cbind
from
SummarizedExperiment object.
example(PhosphoExperiment, echo = FALSE)
n = ncol(phosData)
ppe1 = phosData[,seq(round(n/2))]
ppe2 = phosData[,-seq(round(n/2))]
ppe = cbind(ppe1, ppe2)
identical(ppe, phosData)
#> [1] TRUE
ppe[,seq(round(n/2))] = ppe1
identical(ppe, phosData)
#> [1] TRUE
p = nrow(phosData)
ppe1 = phosData[seq(round(p/2)),]
ppe2 = phosData[-seq(round(p/2)),]
ppe = rbind(ppe1, ppe2)
identical(ppe, phosData)
#> [1] FALSE
ppe[seq(round(p/2)),] = ppe1
identical(ppe, phosData)
#> [1] FALSE