Description Usage Arguments Value Examples
estimate
would estimate the parameters and print the details of estimation.
1 |
X |
list of vectors of observed chain x. |
RNA |
list of 0-1 vectors. 1 if next 3-base is stop codon. |
E |
vector of normalizing constant for observed chain x. |
init |
list of initial parameters. 3 variables: v, m, trans. |
tol |
scalar of tolerance. Default is 0.001. |
detail |
logical; if TRUE, the details of estimation are printed. |
... |
user can put a list of control parameters that would be passed to optim(). E.g.: control=list(maxit=1e4, reltol=1e-9) |
A list containing:
v: shape parameters
m: mean parameters
trans: transition probability c(rho_u, rho, delta)
iter, number of iterations used
Print the class: res
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | k <- 5 # number of transcripts from each group (see data ?uORF)
ii <- c()
for (i in 1:5){
ii <- c(ii, ((i-1)*100+1):((i-1)*100+k))
}
print(ii)
df <- uORF[ii]
X <- RNA <- list(); E <- c()
for (i in 1:length(df)){
X[[i]] <- df[[i]]$x
RNA[[i]] <- df[[i]]$RNA
E[i] <- df[[i]]$E
}
init <- init_generate(df, cutoff=10, r=4)
res <- estimate(X, RNA, E, init, tol=0.001, detail=TRUE)
print(res)
print(df[[1]]$trans)
m <- df[[1]]$m; v <- df[[1]]$v
m_hat <- res$m_hat
v_hat <- res$v_hat
cbind(c(m[1:10],NA), c(m_hat[1:10],NA), c(m_hat[1:10],NA)-c(m[1:10],NA),
m[11:21], m_hat[11:21], m_hat[11:21]-m[11:21])
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.