spatial2D | R Documentation |
Generate a PCA plot with smoothed probability contours
spatial2D( object, params, fcol = "markers", dims = c(1, 2), cov.function = NULL, theta = 2, derivative = 2, k = 1, cond = 1, n = 1, breaks = c(0.99, 0.95, 0.9, 0.85, 0.8, 0.75, 0.7), aspect = 0.5 )
object |
An instance of class |
params |
An instance of class |
fcol |
Feature columns that defines the markers. Defaults to "markers". |
dims |
The PCA dimensions to plot. Defaults to |
cov.function |
The covariance function for the smoothing kernel. Defaults to wendland.cov |
theta |
The theta parameter of the wendland.cov. Defaults to 2. |
derivative |
The derivative paramter of the wendland.cov. Defaults to 2. |
k |
The k parameter of the wendland.cov |
cond |
Which conditions do we want to plot. Must be |
n |
The chain from which we plot the probability distribution. Default is 1. |
breaks |
The levels at which to plot the contours. Defaults to c(0.99, 0.95, 0.9, 0.85, 0.8, 0.75, 0.7) |
aspect |
The aspect ratio of the pca plots. Defaults to 0.5. |
returns a named vector of differential localisation probabilities
## Not run: ## Generate some example data library("pRolocdata") data("tan2009r1") set.seed(1) tansim <- sim_dynamic(object = tan2009r1, numRep = 4L, numDyn = 100L) data <- tansim$lopitrep control <- data[1:2] treatment <- data[3:4] ## fit GP params gpParams <- lapply(tansim$lopitrep, function(x) fitGPmaternPC(x, hyppar = matrix(c(0.5, 1, 100), nrow = 1))) ## run bandle res <- bandle(objectCond1 = control, objectCond2 = treatment, gpParams = gpParams, fcol = "markers", numIter = 5L, burnin = 1L, thin = 2L, numChains = 1, BPPARAM = SerialParam(RNGseed = 1), seed = 1) ## Process the results bandleres <- bandleProcess(res) ## plot the results spatial2D(control[[1]], bandleres) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.