A function to simulate dynamic spatial proteomics data using a bootstrap method
sim_dynamic(
object,
subsample = NULL,
knn_par = 10L,
fcol = "markers",
numRep = 6L,
method = "wild",
batch = FALSE,
frac_perm = FALSE,
nu = 2,
numDyn = 20L
)
A instance of class MSnSet
from which to generate a spatial
proteomics dataset.
how many proteins to subsample to speed up analysis. Default is NULL.
the number of nearest neighbours to use in KNN classification to simulate dataset. Default is 10
feature column to indicate markers. Default is "markers". Proteins with unknown localisations must be encoded as "unknown".
The total number of datasets to generate. Default is 6. An integer must be provided
The bootstrap method to use to simulate dataset. Default is "wild". refer to BANDLE paper for more details.
Whether or not to include batch effects. Default is FALSE.
whether or not to permute the fractions. Default is FALSE
parameter to generate residual inflated noise. Default is 2. See BANDLE paper for more details
An integer number of protein to simulate dynamic transitions. Default is 20
returns simulate dynamic lopit datasets and the name of the relocalated protein.
library(pRolocdata)
data("tan2009r1")
set.seed(1)
tansim <- sim_dynamic(object = tan2009r1, numRep = 6L, numDyn = 100L)