labeled inverse average expression: relative frequency
iae_rf(expr, features = NULL, label, multi = TRUE, thres = 0)a matrix of inverse average expression score
$$\mathbf{IAE} = log(1+\frac{mean(N_{i,j\in D})}{max(mean(N_{i,j\in \hat D}))+ e^{-8}})$$ where \(N_{i,j\in D}\) is the counts of feature \(i\) in cell \(j\) within class \(D\), and \(\hat D\) is the class except \(D\).
data <- matrix(rpois(100, 2), 10, dimnames = list(1:10))
smartid:::iae_rf(data, label = sample(c("A", "B"), 10, replace = TRUE))
#> A A B B B A A
#> 1 0.4700036 0.4700036 0.9808292 0.9808292 0.9808292 0.4700036 0.4700036
#> 2 0.8649974 0.8649974 0.5465437 0.5465437 0.5465437 0.8649974 0.8649974
#> 3 0.9694006 0.9694006 0.4769241 0.4769241 0.4769241 0.9694006 0.9694006
#> 4 0.8383292 0.8383292 0.5663955 0.5663955 0.5663955 0.8383292 0.8383292
#> 5 0.6701577 0.6701577 0.7166777 0.7166777 0.7166777 0.6701577 0.6701577
#> 6 1.6486586 1.6486586 0.2135741 0.2135741 0.2135741 1.6486586 1.6486586
#> 7 0.8007778 0.8007778 0.5959834 0.5959834 0.5959834 0.8007778 0.8007778
#> 8 0.8649974 0.8649974 0.5465437 0.5465437 0.5465437 0.8649974 0.8649974
#> 9 0.3566749 0.3566749 1.2039728 1.2039728 1.2039728 0.3566749 0.3566749
#> 10 0.5978370 0.5978370 0.7985077 0.7985077 0.7985077 0.5978370 0.5978370
#> B B B
#> 1 0.9808292 0.9808292 0.9808292
#> 2 0.5465437 0.5465437 0.5465437
#> 3 0.4769241 0.4769241 0.4769241
#> 4 0.5663955 0.5663955 0.5663955
#> 5 0.7166777 0.7166777 0.7166777
#> 6 0.2135741 0.2135741 0.2135741
#> 7 0.5959834 0.5959834 0.5959834
#> 8 0.5465437 0.5465437 0.5465437
#> 9 1.2039728 1.2039728 1.2039728
#> 10 0.7985077 0.7985077 0.7985077