Hu Algorithm

function 1 : log-likelihood to estimate logmu
  • f(logmu) = $\sum(\frac{1}{2}*logsigma2 + \frac{(X-exp(logmu))^2}{2*exp(logsigma2)})$
  • logsigma2 = beta0 + beta1 * logmu
function 2 : log-likelihood to estimate beta
  • f(beta) = $\sum(\frac{1}{2}*logsigma2 + \frac{(X-exp(logmu))^2}{2*exp(logsigma2)})$
  • logsigma2 = beta[1] + beta[2] * logmu

Data Preprocessing

  1. seperate the original data set to two matrix.
    $M_1$ = data in group1
    $M_2$ = data in group2
  2. calculate rchisq $rchisq_1$ for $M_1$, $rchisq_2$ for $M_2$ based on 10^6 time runs
  3. calculate variance $Var_1$ of $rchisq_1$ , $Var_2$ of $rchisq_2$
  4. calculate 1% quantile $Quan_1$, mean $Mean_1$, variance $Variance_1$ of $M_1$, $Quan_2$, mean $Mean_2$, variance $Variance_2$ of $M_2$without NAN and negative values
    n is sample of population, x is value corresponding to each sample
    (a) mean = $\sum x $/ n
    (b) variance = $\frac{n*\sum {X}^2-(\sum X)^2 }{n*(n-1)}$
    (c) 1% quantile = value at (pos-1) + diff_v*diff_p
    position = 1 + (n-1)*0.01
    pos = integer part of position
    diff_p = position - pos
    diff_v = ceiling of value at (position - 1 ) - value at (pos-1)
  5. replace NA and negative values in $M_1$ with $Quan_1$, $M_2$ with $Quan_2$

Estimate MLE

  1. calculate coefficients and residuals based on log values of $M_1$ and $Var_1$, $M_2$ and $Var_2$
    x are values in M, y are values in Quan
    coefficients :
    (a) intercept of coefficient = $\frac{n\sum{xy}-\sum x  \sum y}{n\sum {x}^2 -(\sum X)^2 }$
    (b) slope of coefficient = y - intercept * x
    residuals = y - (intercept + slope * x)
  2. xd2hat = variance of residuals - Var
  3. calculate initial values xinitial = estimate value of nlm
  4. lkdsumsloop loop 3 times to calculate lkdinitial
    if lkdinf-lkdsumsloop[3] >= 1
    then lkdsumsloop== lkdsumsloop[-1]

    (a) calaulate min and estimate of xinitial
    (b) lkdinitial = $\sum{min}$
  5. calculate lkdinf
    lkdinf = lkdsumsloop[1]+ \begin{displaymath} \frac{1}{(1-\frac{lkdsumsloop[3]-lkdsumsloop[2]}{lkdsumsloop[2]-lkdsumsloop[1]})*(lkdsumsloop[2]-lkdsumsloop[1])} \end{displaymath}
  6. calcualte mle estimate of mean expression, mle estimate of variance of each gene
    (a) xbeta.mle = xinitial[(m+1):(m+2)]
    (b) xbar.mle = exponent of xinitial
    (c) xs2.mle = exponent of xbeta.mle * xbar.mle ^ xbeta.mle

calculate Hu score

score = |$\frac{xbar1.mle - xbar2.mle}{\sqrt{xs1.mle+\frac{xs2.mle}{6}}}$|

Remarks

  • Details of nlm calculation have been skipped.
Edit | Attach | Print version | History: r13 | r11 < r10 < r9 < r8 | Backlinks | View wiki text | Edit WikiText | More topic actions...
Topic revision: r10 - 13 Sep 2005, ColeBeck
 

This site is powered by FoswikiCopyright © 2013-2022 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Vanderbilt Biostatistics Wiki? Send feedback