Quick start of BALLI package

Quick Start

This is an quick start manual of BALLI

require(BALLI)

1. Load Count Data

data <- data.frame(read.table("counts.txt"))

or make example count data

##       A1 A2  A3  A4 A5  A6  A7  A8  A9 A10  B1  B2  B3 B4  B5  B6 B7  B8
## gene1  7 39  16  80 48  40 128  48  14  59 160  46  23 63  24 108 40  19
## gene2 33 39 112  24 74  61 167 124  89  95  95 151 206 54 224  66 45 110
## gene3 82 68  39 159 43 103  67 102 182  47  97  97  93 60  74  82 70 109
## gene4 13 18  14  15  6  20  17  11  11   6  13  15   2 12  12  17 13  14
## gene5 10 14  40  26 19  22  19  22  27  20  13   9  17 25  18  12 15  54
## gene6 50 71  20  13 22  10  26  23  10  40  13  22  16 43  42  30 35  43
##       B9 B10
## gene1 22  68
## gene2 75  62
## gene3 56  34
## gene4  5  20
## gene5 16  23
## gene6 26  33

2. Designate Group Information and Make Design Matrix

##  [1] "A" "A" "A" "A" "A" "A" "A" "A" "A" "A" "B" "B" "B" "B" "B" "B" "B"
## [18] "B" "B" "B"
##   (Intercept) GroupB
## 1           1      0
## 2           1      0
## 3           1      0
## 4           1      0
## 5           1      0
## 6           1      0

3. Normalize Count Data

## An object of class "DGEList"
## $counts
##       A1 A2  A3  A4 A5  A6  A7  A8  A9 A10  B1  B2  B3 B4  B5  B6 B7  B8
## gene1  7 39  16  80 48  40 128  48  14  59 160  46  23 63  24 108 40  19
## gene2 33 39 112  24 74  61 167 124  89  95  95 151 206 54 224  66 45 110
## gene3 82 68  39 159 43 103  67 102 182  47  97  97  93 60  74  82 70 109
## gene4 13 18  14  15  6  20  17  11  11   6  13  15   2 12  12  17 13  14
## gene5 10 14  40  26 19  22  19  22  27  20  13   9  17 25  18  12 15  54
##       B9 B10
## gene1 22  68
## gene2 75  62
## gene3 56  34
## gene4  5  20
## gene5 16  23
## 9995 more rows ...
## 
## $samples
##    group lib.size norm.factors
## A1     A   551929    0.9939824
## A2     A   554250    1.0019442
## A3     A   551469    0.9964722
## A4     A   551560    1.0071093
## A5     A   546462    0.9998596
## 15 more rows ...

4. Estimate Technical Variance

## An object of class "TecVarList"
## $targets
##    group lib.size norm.factors
## A1     A 548607.7    0.9939824
## A2     A 555327.6    1.0019442
## A3     A 549523.5    0.9964722
## A4     A 555481.2    1.0071093
## A5     A 546385.3    0.9998596
## 15 more rows ...
## 
## $design
##   (Intercept) GroupB
## 1           1      0
## 2           1      0
## 3           1      0
## 4           1      0
## 5           1      0
## 15 more rows ...
## 
## $logcpm
##             A1       A2       A3       A4       A5       A6       A7
## gene1 4.034259 6.206591 5.033024 7.205971 6.515297 6.237959 7.888394
## gene2 5.994961 6.206591 7.696526 5.549376 7.119559 6.822715 8.266935
## gene3 7.258266 6.978131 6.221008 8.179219 6.363232 7.559515 6.974440
## gene4 4.771948 5.171450 4.863019 4.936799 3.868508 5.305636 5.113222
## gene5 4.449749 4.849758 6.255780 5.656237 5.262988 5.431069 5.257693
##             A8       A9      A10       B1       B2       B3       B4
## gene1 6.510839 4.849230 6.797026 8.221498 6.447280 5.477148 6.882641
## gene2 7.844489 7.355990 7.466305 7.481365 8.119834 8.531824 6.667616
## gene3 7.567617 8.371645 6.480929 7.510818 7.491771 7.401550 6.814466
## gene4 4.566359 4.549959 3.864428 4.785661 4.949437 2.844617 4.667364
## gene5 5.451541 5.706648 5.325222 4.785661 4.321116 5.081903 5.615058
##             B5       B6       B7       B8       B9      B10
## gene1 5.559786 7.627629 6.240335 5.251725 5.455301 6.978569
## gene2 8.679625 6.933867 6.402553 7.666884 7.137895 6.849310
## gene3 7.107348 7.238655 7.017734 7.653945 6.728975 6.019453
## gene4 4.666604 5.095240 4.755808 4.859361 3.674976 5.309277
## gene5 5.181240 4.655118 4.936215 6.666856 5.039891 5.493604
## 9995 more rows ...
## 
## $tecVar
##               A1         A2         A3         A4         A5         A6
## gene1 0.02433482 0.02404494 0.02429490 0.02403839 0.02443225 0.02398665
## gene2 0.01290915 0.01276419 0.01288908 0.01276092 0.01295810 0.01273506
## gene3 0.01157954 0.01144914 0.01156159 0.01144619 0.01162334 0.01142290
## gene4 0.06724111 0.06647979 0.06713630 0.06646259 0.06749685 0.06632664
## gene5 0.04159129 0.04110131 0.04152382 0.04109025 0.04175595 0.04100278
##               A7         A8         A9        A10         B1          B2
## gene1 0.02433497 0.02435499 0.02403503 0.02434190 0.01994302 0.019683524
## gene2 0.01290922 0.01291928 0.01275924 0.01291270 0.00991243 0.009788362
## gene3 0.01157961 0.01158861 0.01144467 0.01158272 0.01245367 0.012299260
## gene4 0.06724149 0.06729405 0.06645375 0.06725969 0.07659121 0.075636970
## gene5 0.04159154 0.04162538 0.04108456 0.04160325 0.04821743 0.047601141
##                B3          B4          B5          B6          B7
## gene1 0.019272708 0.019654898 0.019643162 0.019466946 0.019486113
## gene2 0.009591265 0.009774668 0.009769053 0.009684516 0.009693714
## gene3 0.012053776 0.012282216 0.012275228 0.012169979 0.012181437
## gene4 0.074120695 0.075531652 0.075488473 0.074838233 0.074909017
## gene5 0.046619411 0.047532925 0.047504959 0.047083888 0.047129718
##                B8          B9         B10
## gene1 0.019644458 0.019802616 0.019505915
## gene2 0.009769673 0.009845315 0.009703217
## gene3 0.012275999 0.012370146 0.012193274
## gene4 0.075493239 0.076075022 0.074982142
## gene5 0.047508046 0.047884242 0.047177065
## 9995 more rows ...

5. Fit BALLI and See Top Significant Genes

## An object of class "Balli"
## $Result
##       log2FC_GroupB      lLLI    lBALLI      pLLI    pBALLI       BCF
## gene1     0.2862964 0.3791686 0.3370391 0.5380485 0.5615433 0.1249988
## gene2     0.4147916 1.3275686 1.1800625 0.2492382 0.2773433 0.1249985
## gene3    -0.0970422 0.1338105 0.1189427 0.7145134 0.7301840 0.1249997
## gene4    -0.1410062 0.2757014 0.2450759 0.5995326 0.6205638 0.1249635
## gene5    -0.1870295 0.5887311 0.5233292 0.4429102 0.4694250 0.1249728
## 9995 more rows ...
## 
## $topGenes
##          log2FC_GroupB         pLLI       pBALLI   adjpLLI adjpBALLI
## gene6890    -0.8492182 1.197256e-05 3.663179e-05 0.1121975 0.3204511
## gene7128     0.9149524 2.243950e-05 6.409023e-05 0.1121975 0.3204511
## gene3277    -1.2590606 8.539749e-05 2.121336e-04 0.2846583 0.6766089
## gene7092    -1.5531435 1.637869e-04 3.799606e-04 0.3555333 0.6766089
## gene4606     1.4661759 2.563216e-04 5.668673e-04 0.3555333 0.6766089
## 9995 more rows ...

mirror server hosted at Truenetwork, Russian Federation.