Description Usage Arguments Value Author(s) References Examples
View source: R/FindBestTransform.R
Find a constant alpha, 0<alpha<=1, such that x raised to the power alpha approximately follows the simple Poisson log linear model that says that the (i,j) element of x is Poisson with mean si times gj, where si is a sample-specific term and gj is a feature-specific term. Alpha is selected via a grid search.
1 |
x |
A n-by-p matrix of sequencing data, with n observations and p features. |
Returns alpha, the power to which x should be raised.
Daniela Witten
D Witten (2011) Classification and clustering of sequencing data using a Poisson model. To appear in Annals of Applied Statistics.
1 2 3 4 5 6 7 8 9 10 | set.seed(1)
dat <- CountDataSet(n=20,p=100,sdsignal=2,K=4,param=10)
alpha <- FindBestTransform(dat$x)
# This is the best transformation!
dd <- PoissonDistance(dat$x^alpha,type="mle", transform=FALSE)
# OR we could get the samething automatically:
dd2 <- PoissonDistance(dat$x,type="mle",transform=TRUE)
# or like this:
dd3 <- PoissonDistance(dat$x,type="mle",transform=TRUE,alpha=alpha)
ColorDendrogram(hclust(dd$dd), y=dat$y, branchlength=10)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.