Description Usage Arguments Value See Also Examples
Compute frequencies or counts of gene segments ("V / J - usage").
1 2 3 4 5 6 7 | geneUsage(
.data,
.genes = HUMAN_TRBV_MITCR,
.quant = c(NA, "read.count", "umi.count", "read.prop", "umi.prop"),
.norm = F,
.ambig = F
)
|
.data |
Cloneset data frame or a list with clonesets. |
.genes |
Either one of the gene alphabet (e.g., HUMAN_TRBV, genealphabets) or list with two gene alphabets for computing joint distribution. |
.quant |
Which column to use for the quantity of clonotypes: NA for computing only number of genes without using clonotype counts, "read.count" for the "Read.count" column, "umi.count" for the "Umi.count" column, "read.prop" for the "Read.proportion" column, "umi.prop" for the "Umi.proportion" column. |
.norm |
If T then return proportions of resulting counting of genes. |
.ambig |
If F than remove from counting genes which are not presented in the given gene alphabet(s). |
If .data
is a cloneset and .genes
is NOT a list than return a data frame with first column "Gene" with genes and second with counts / proportions.
If .data
is a list with clonesets and .genes
is NOT a list than return a data frame with first column "Gene"
with genes and other columns with counts / proportions for each cloneset in the input list.
If .data
is a cloneset and .genes
IS a list than return a matrix with gene segments for the first gene in .genes
and column names for the second gene in .genes
. See "Examples".
If .data
is a list with clonesets and .genes
IS a list than return a list with matrices like in the previous case.
genealphabets
, vis.gene.usage
, pca.segments
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## Not run:
# Load your data
data(twb)
# compute V-segments frequencies of human TCR beta.
seg <- geneUsage(twb, HUMAN_TRBV, .norm = T)
# plot V-segments frequencies as a heatmap
vis.heatmap(seg, .labs = c("Sample", "V gene"))
# plot V-segments frequencies directly from clonesets
vis.gene.usage(twb, HUMAN_TRBV)
# plot V-segments frequencies from the gene frequencies
vis.gene.usage(seg, NA)
# Compute V-J joint usage.
geneUsage(twb, list(HUMAN_TRBV, HUMAN_TRBJ))
# for future:
# geneUsage(twb, "human", "trbv")
## End(Not run)
|
Loading required package: ggplot2
Loading required package: dplyr
Attaching package: 'dplyr'
The following objects are masked from 'package:stats':
filter, lag
The following objects are masked from 'package:base':
intersect, setdiff, setequal, union
Loading required package: gridExtra
Attaching package: 'gridExtra'
The following object is masked from 'package:dplyr':
combine
Loading required package: reshape2
Loading required package: igraph
Attaching package: 'igraph'
The following objects are masked from 'package:dplyr':
as_data_frame, groups, union
The following objects are masked from 'package:stats':
decompose, spectrum
The following object is masked from 'package:base':
union
sh: 1: wc: Permission denied
sh: 1: cannot create /dev/null: Permission denied
Could not detect number of cores, defaulting to 1.
Attaching package: 'tcR'
The following object is masked from 'package:igraph':
diversity
Warning: Ignoring unknown aesthetics: fill
Using Gene as id variables
Using Gene as id variables
$Subj.A
TRBJ1-1 TRBJ1-2 TRBJ1-3 TRBJ1-4 TRBJ1-5 TRBJ1-6 TRBJ2-1 TRBJ2-2
TRBV10-1 6 1 0 1 1 0 9 8
TRBV10-2 5 5 1 1 5 3 6 3
TRBV10-3 42 24 11 6 29 15 58 20
TRBV11-1 6 2 0 0 0 2 11 5
TRBV11-2 23 11 4 10 6 3 48 11
TRBV12-5 3 2 0 0 1 1 4 1
TRBV11-3 1 1 1 0 3 1 4 2
TRBV13 13 5 2 3 2 3 5 9
TRBV14 27 6 6 5 4 3 17 10
TRBV15 8 7 0 9 4 0 8 5
TRBV16 4 1 0 1 0 1 0 0
TRBV18 40 18 11 21 22 5 27 8
TRBV19 36 16 3 6 32 5 79 33
TRBV2 47 37 12 21 47 17 72 37
TRBV20-1 120 82 21 31 112 42 145 53
TRBV21-1 22 8 5 3 12 9 15 12
TRBV23-1 3 0 0 3 10 3 11 13
TRBV24-1 25 22 1 4 14 2 46 35
TRBV25-1 10 9 3 7 3 7 9 14
TRBV27 33 24 4 12 31 10 32 28
TRBV28 139 91 22 54 116 35 119 73
TRBV29-1 250 133 33 48 81 6 212 129
TRBV3-1 40 17 9 10 9 7 21 22
TRBV30 11 5 4 4 10 3 12 13
TRBV4-1 12 12 5 11 9 3 19 13
TRBV4-2 11 8 3 10 7 5 30 16
TRBV4-3 13 11 4 10 7 5 28 15
TRBV5-1 46 22 5 19 14 8 26 20
TRBV5-4 10 1 1 5 2 3 14 9
TRBV5-5 9 4 2 3 10 1 5 8
TRBV5-6 15 2 1 1 6 5 15 9
TRBV5-8 1 0 0 4 2 0 5 2
TRBV6-1 24 9 5 9 20 8 22 21
TRBV6-4 15 7 0 1 10 3 106 55
TRBV6-6 29 18 9 15 20 8 27 17
TRBV6-5 72 35 14 24 27 22 54 40
TRBV7-2 47 21 13 12 18 14 39 24
TRBV7-3 17 3 4 2 5 2 27 14
TRBV7-4 0 0 0 0 0 0 1 1
TRBV7-6 10 3 2 3 6 4 15 23
TRBV7-7 1 0 2 0 1 1 5 4
TRBV7-8 13 4 4 2 12 3 21 6
TRBV7-9 51 25 8 9 18 13 46 14
TRBV9 30 11 6 7 7 8 37 24
TRBV12-4 0 0 0 0 0 0 0 0
TRBV12-3 0 0 0 0 0 0 0 0
TRBV6-3 0 0 0 0 0 0 0 0
TRBV6-2 0 0 0 0 0 0 0 0
TRBV6-7 0 0 0 0 0 0 0 0
TRBJ2-3 TRBJ2-4 TRBJ2-5 TRBJ2-6 TRBJ2-7
TRBV10-1 9 0 1 0 4
TRBV10-2 7 0 6 0 6
TRBV10-3 29 0 16 3 55
TRBV11-1 6 1 3 0 7
TRBV11-2 20 5 18 0 27
TRBV12-5 2 0 0 0 1
TRBV11-3 2 0 3 0 2
TRBV13 7 2 9 0 8
TRBV14 12 4 5 0 14
TRBV15 12 0 5 1 3
TRBV16 0 0 0 0 1
TRBV18 30 2 13 0 24
TRBV19 28 6 7 2 33
TRBV2 61 12 23 2 43
TRBV20-1 99 20 51 8 166
TRBV21-1 15 5 11 1 23
TRBV23-1 7 4 4 0 7
TRBV24-1 32 2 14 0 14
TRBV25-1 8 0 2 1 10
TRBV27 22 2 17 3 38
TRBV28 82 16 52 9 185
TRBV29-1 170 21 79 5 146
TRBV3-1 23 2 7 2 15
TRBV30 16 0 2 2 14
TRBV4-1 10 2 4 0 21
TRBV4-2 25 1 6 5 21
TRBV4-3 17 5 6 7 24
TRBV5-1 29 1 11 2 27
TRBV5-4 12 1 3 0 6
TRBV5-5 11 0 0 1 2
TRBV5-6 4 0 2 1 12
TRBV5-8 2 3 0 0 3
TRBV6-1 22 1 8 5 19
TRBV6-4 121 1 3 4 8
TRBV6-6 13 4 9 3 16
TRBV6-5 38 2 14 2 48
TRBV7-2 42 9 17 3 42
TRBV7-3 23 2 7 1 3
TRBV7-4 0 0 0 0 0
TRBV7-6 11 0 7 0 17
TRBV7-7 3 0 4 0 1
TRBV7-8 7 1 6 0 21
TRBV7-9 36 4 15 1 29
TRBV9 24 2 11 4 22
TRBV12-4 0 0 0 0 0
TRBV12-3 0 0 0 0 0
TRBV6-3 0 0 0 0 0
TRBV6-2 0 0 0 0 0
TRBV6-7 0 0 0 0 0
$Subj.B
TRBJ1-1 TRBJ1-2 TRBJ1-3 TRBJ1-4 TRBJ1-5 TRBJ1-6 TRBJ2-1 TRBJ2-2
TRBV10-1 3 2 1 1 2 2 6 4
TRBV10-2 9 8 1 0 7 5 10 8
TRBV10-3 42 28 11 9 32 5 37 32
TRBV11-1 9 1 0 0 0 0 8 1
TRBV11-2 26 18 8 9 11 8 33 27
TRBV12-5 3 1 2 0 1 0 5 3
TRBV11-3 1 1 0 0 4 0 10 3
TRBV13 10 7 2 0 0 2 4 5
TRBV14 27 9 2 4 2 4 11 11
TRBV15 6 4 1 3 4 4 8 6
TRBV16 6 1 0 1 1 1 1 0
TRBV18 57 17 14 16 21 7 20 23
TRBV19 50 24 2 6 55 7 62 21
TRBV2 63 35 12 24 54 15 54 32
TRBV20-1 132 91 22 37 102 48 142 65
TRBV21-1 17 7 2 5 5 7 16 4
TRBV23-1 2 1 1 2 8 0 12 4
TRBV24-1 11 18 7 4 14 2 46 42
TRBV25-1 16 10 4 6 6 7 9 9
TRBV27 33 17 5 16 24 22 36 18
TRBV28 141 115 35 55 115 35 116 64
TRBV29-1 197 137 18 51 73 11 149 78
TRBV3-1 35 11 13 8 22 9 26 15
TRBV30 17 7 4 4 18 6 17 7
TRBV4-1 14 11 2 5 9 6 16 11
TRBV4-2 15 16 5 6 8 2 20 9
TRBV4-3 23 18 11 12 6 12 19 17
TRBV5-1 72 27 7 21 10 15 36 30
TRBV5-4 10 2 3 8 0 3 17 5
TRBV5-5 8 12 1 1 4 1 8 8
TRBV5-6 10 7 2 2 11 2 21 10
TRBV5-8 0 1 1 0 0 2 2 0
TRBV6-1 26 11 12 10 30 11 18 17
TRBV6-4 14 7 0 2 8 4 59 56
TRBV6-6 38 16 12 9 27 9 19 14
TRBV6-5 65 45 19 12 31 22 53 29
TRBV6-7 1 0 0 0 0 0 0 0
TRBV7-1 0 0 0 0 0 0 0 1
TRBV7-2 45 25 13 23 25 9 42 35
TRBV7-3 12 5 4 1 1 3 21 19
TRBV7-4 2 2 0 0 0 0 0 0
TRBV7-6 7 4 4 2 4 5 18 15
TRBV7-7 4 0 0 1 4 0 1 9
TRBV7-8 11 2 4 4 8 4 23 8
TRBV7-9 42 14 8 15 22 10 42 16
TRBV9 21 21 5 6 12 7 37 34
TRBV12-4 0 0 0 0 0 0 0 0
TRBV12-3 0 0 0 0 0 0 0 0
TRBV6-3 0 0 0 0 0 0 0 0
TRBJ2-3 TRBJ2-4 TRBJ2-5 TRBJ2-6 TRBJ2-7
TRBV10-1 7 0 1 0 6
TRBV10-2 8 1 1 0 7
TRBV10-3 35 2 18 3 53
TRBV11-1 4 1 4 0 6
TRBV11-2 38 7 17 1 27
TRBV12-5 2 0 1 0 4
TRBV11-3 2 0 1 0 1
TRBV13 2 0 1 0 6
TRBV14 10 4 6 1 16
TRBV15 9 1 5 1 6
TRBV16 1 0 0 1 2
TRBV18 24 2 14 1 23
TRBV19 24 2 7 2 32
TRBV2 51 3 21 0 40
TRBV20-1 122 25 39 7 133
TRBV21-1 17 5 7 1 15
TRBV23-1 8 0 7 0 10
TRBV24-1 28 1 7 0 13
TRBV25-1 9 2 4 0 12
TRBV27 30 3 14 2 35
TRBV28 84 19 47 13 169
TRBV29-1 132 20 71 12 111
TRBV3-1 29 7 12 1 18
TRBV30 8 1 5 4 12
TRBV4-1 13 5 8 0 21
TRBV4-2 41 0 9 5 13
TRBV4-3 21 0 11 8 16
TRBV5-1 41 4 11 2 39
TRBV5-4 16 1 7 1 9
TRBV5-5 11 0 2 1 10
TRBV5-6 7 1 7 1 17
TRBV5-8 1 7 2 0 1
TRBV6-1 19 1 12 1 22
TRBV6-4 95 4 1 8 6
TRBV6-6 24 3 9 1 23
TRBV6-5 44 4 27 10 57
TRBV6-7 0 0 0 0 0
TRBV7-1 0 0 0 0 0
TRBV7-2 65 5 27 2 43
TRBV7-3 30 1 3 4 9
TRBV7-4 1 0 0 0 1
TRBV7-6 9 0 10 0 15
TRBV7-7 4 0 1 0 1
TRBV7-8 13 2 3 0 13
TRBV7-9 42 7 9 0 19
TRBV9 37 2 10 0 21
TRBV12-4 0 0 0 0 0
TRBV12-3 0 0 0 0 0
TRBV6-3 0 0 0 0 0
$Subj.C
TRBJ1-1 TRBJ1-2 TRBJ1-3 TRBJ1-4 TRBJ1-5 TRBJ1-6 TRBJ2-1 TRBJ2-2
TRBV10-1 1 2 0 0 2 0 3 1
TRBV10-2 6 2 0 2 1 1 1 1
TRBV10-3 50 20 15 17 28 14 49 33
TRBV11-1 10 0 1 0 1 0 9 4
TRBV11-2 39 13 4 6 6 5 40 32
TRBV12-5 8 2 0 2 11 1 4 7
TRBV11-3 3 0 1 1 3 0 7 8
TRBV13 12 3 0 2 2 2 3 4
TRBV14 22 10 3 4 7 4 14 17
TRBV15 6 1 7 5 6 1 5 3
TRBV16 4 0 0 1 0 0 0 0
TRBV18 45 16 5 16 19 3 22 15
TRBV19 51 17 8 6 40 6 22 26
TRBV2 97 39 14 30 57 18 59 63
TRBV20-1 243 104 43 61 107 31 138 90
TRBV21-1 16 10 3 10 17 2 13 9
TRBV23-1 0 0 0 2 3 0 2 0
TRBV24-1 12 11 2 2 11 1 22 21
TRBV25-1 30 9 6 6 17 7 19 13
TRBV27 34 16 4 12 32 8 12 14
TRBV28 101 48 22 34 84 19 54 53
TRBV29-1 246 96 37 46 48 10 95 57
TRBV3-1 66 23 13 13 20 8 41 31
TRBV30 10 4 1 2 5 0 3 7
TRBV4-1 70 38 13 36 25 11 20 25
TRBV4-2 19 8 1 6 7 5 16 16
TRBV4-3 35 22 22 21 14 12 35 41
TRBV5-1 196 65 25 52 28 26 117 106
TRBV5-4 6 2 0 1 0 0 8 3
TRBV5-5 10 4 0 0 1 0 3 3
TRBV5-6 16 4 3 4 6 2 12 8
TRBV5-8 7 0 0 1 0 0 0 0
TRBV6-1 21 9 8 2 25 3 11 17
TRBV6-4 10 3 2 2 13 1 28 27
TRBV6-6 37 20 7 19 27 7 12 12
TRBV6-5 46 21 11 21 17 9 18 23
TRBV6-7 0 0 1 1 0 0 1 0
TRBV7-2 63 36 35 28 36 17 55 38
TRBV7-3 11 0 1 1 4 1 5 4
TRBV7-4 0 0 0 0 1 0 0 1
TRBV7-6 11 0 4 2 5 3 3 6
TRBV7-7 6 0 0 0 0 0 11 3
TRBV7-8 15 6 6 9 6 4 10 9
TRBV7-9 75 23 16 23 18 6 24 16
TRBV9 39 20 16 5 14 9 40 31
TRBV12-4 0 0 0 0 0 0 0 0
TRBV12-3 0 0 0 0 0 0 0 0
TRBV6-3 0 0 0 0 0 0 0 0
TRBV6-2 0 0 0 0 0 0 0 0
TRBJ2-3 TRBJ2-4 TRBJ2-5 TRBJ2-6 TRBJ2-7
TRBV10-1 0 0 0 0 0
TRBV10-2 3 0 3 1 1
TRBV10-3 48 3 15 0 36
TRBV11-1 5 0 0 1 2
TRBV11-2 31 7 14 1 25
TRBV12-5 2 0 0 0 0
TRBV11-3 2 1 1 0 0
TRBV13 7 0 2 0 7
TRBV14 10 0 3 0 14
TRBV15 7 1 1 0 3
TRBV16 1 1 0 0 2
TRBV18 22 4 8 1 19
TRBV19 17 1 8 2 13
TRBV2 53 9 21 0 35
TRBV20-1 151 15 83 2 117
TRBV21-1 8 2 8 0 17
TRBV23-1 0 0 0 0 2
TRBV24-1 23 3 4 1 2
TRBV25-1 24 3 10 1 29
TRBV27 21 4 3 0 16
TRBV28 71 12 29 4 63
TRBV29-1 134 11 65 6 58
TRBV3-1 30 4 17 1 31
TRBV30 2 1 2 0 0
TRBV4-1 47 3 9 1 29
TRBV4-2 17 2 5 2 15
TRBV4-3 38 2 9 2 15
TRBV5-1 162 8 16 4 69
TRBV5-4 4 0 1 0 0
TRBV5-5 5 1 1 0 1
TRBV5-6 8 1 0 1 7
TRBV5-8 2 0 0 0 0
TRBV6-1 10 1 2 2 3
TRBV6-4 31 0 0 2 2
TRBV6-6 27 4 8 0 11
TRBV6-5 27 2 3 1 13
TRBV6-7 0 0 0 0 0
TRBV7-2 98 13 9 0 29
TRBV7-3 8 1 0 2 1
TRBV7-4 0 0 0 0 0
TRBV7-6 3 0 2 0 7
TRBV7-7 3 0 1 0 3
TRBV7-8 14 2 2 0 4
TRBV7-9 28 3 7 0 16
TRBV9 42 0 7 0 14
TRBV12-4 0 0 0 0 0
TRBV12-3 0 0 0 0 0
TRBV6-3 0 0 0 0 0
TRBV6-2 0 0 0 0 0
$Subj.D
TRBJ1-1 TRBJ1-2 TRBJ1-3 TRBJ1-4 TRBJ1-5 TRBJ1-6 TRBJ2-1 TRBJ2-2
TRBV10-1 12 5 2 4 5 1 8 3
TRBV10-2 4 9 0 1 1 0 4 4
TRBV10-3 59 21 12 14 31 3 38 14
TRBV11-1 3 1 0 0 1 1 0 1
TRBV11-2 29 11 1 4 2 4 22 22
TRBV12-5 5 3 1 1 3 2 4 4
TRBV11-3 4 0 0 2 3 1 9 3
TRBV13 15 4 1 2 1 2 2 5
TRBV14 13 8 4 3 2 1 15 7
TRBV15 9 7 4 4 5 4 12 7
TRBV16 2 1 1 0 1 0 0 0
TRBV18 63 18 5 14 13 6 24 10
TRBV19 31 12 2 3 14 1 15 7
TRBV2 46 36 14 15 39 17 45 38
TRBV20-1 197 93 33 37 85 39 166 77
TRBV21-1 51 39 8 9 42 8 35 20
TRBV23-1 2 3 0 0 2 3 2 0
TRBV24-1 5 3 0 1 2 1 11 6
TRBV25-1 77 19 28 33 41 19 53 40
TRBV27 30 12 2 8 18 3 9 3
TRBV28 155 99 28 38 110 38 65 76
TRBV29-1 373 199 50 79 76 18 167 135
TRBV3-1 47 25 10 11 16 3 40 23
TRBV30 19 5 0 3 5 1 6 20
TRBV4-1 44 19 12 17 28 3 26 14
TRBV4-2 18 9 1 9 4 7 26 25
TRBV4-3 38 20 11 18 8 8 60 27
TRBV5-1 82 35 6 17 17 11 59 43
TRBV5-4 7 7 0 1 0 0 4 0
TRBV5-5 6 1 1 1 2 2 11 4
TRBV5-6 5 3 1 1 4 1 8 5
TRBV5-8 0 1 0 0 1 0 1 0
TRBV6-1 15 6 1 2 11 6 21 15
TRBV6-4 25 8 1 3 11 4 79 59
TRBV6-6 31 15 6 14 19 10 19 11
TRBV6-5 25 22 5 8 19 8 25 21
TRBV6-7 1 1 1 0 1 0 0 0
TRBV7-1 1 0 0 0 0 0 0 0
TRBV7-2 52 48 12 11 18 17 37 26
TRBV7-3 16 6 1 2 6 2 14 12
TRBV7-4 2 0 0 1 0 0 2 0
TRBV7-6 4 3 1 1 3 1 6 5
TRBV7-7 1 0 0 1 1 0 2 3
TRBV7-8 17 8 1 1 2 4 13 5
TRBV7-9 49 22 8 21 15 9 32 10
TRBV9 34 17 7 9 6 6 21 14
TRBV12-4 0 0 0 0 0 0 0 0
TRBV12-3 0 0 0 0 0 0 0 0
TRBV6-3 0 0 0 0 0 0 0 0
TRBJ2-3 TRBJ2-4 TRBJ2-5 TRBJ2-6 TRBJ2-7
TRBV10-1 1 2 0 1 5
TRBV10-2 3 0 2 0 5
TRBV10-3 31 2 16 3 30
TRBV11-1 0 0 1 0 0
TRBV11-2 27 0 5 3 21
TRBV12-5 4 0 1 1 2
TRBV11-3 8 0 2 0 5
TRBV13 10 1 2 0 5
TRBV14 14 0 9 0 10
TRBV15 16 2 2 1 10
TRBV16 0 0 0 1 2
TRBV18 23 3 11 2 24
TRBV19 9 1 2 0 7
TRBV2 49 5 29 1 41
TRBV20-1 117 9 68 3 109
TRBV21-1 24 7 12 2 37
TRBV23-1 1 1 2 1 4
TRBV24-1 5 1 1 2 1
TRBV25-1 54 11 19 3 50
TRBV27 12 4 4 0 13
TRBV28 90 7 33 7 99
TRBV29-1 249 20 67 12 82
TRBV3-1 27 4 11 1 26
TRBV30 7 0 2 4 6
TRBV4-1 34 1 11 2 9
TRBV4-2 36 4 10 5 18
TRBV4-3 38 2 9 9 41
TRBV5-1 84 11 8 1 37
TRBV5-4 6 0 0 0 3
TRBV5-5 6 0 2 1 5
TRBV5-6 6 1 1 0 1
TRBV5-8 0 0 0 0 2
TRBV6-1 15 0 2 3 8
TRBV6-4 100 2 5 4 7
TRBV6-6 18 1 3 1 23
TRBV6-5 15 3 12 6 22
TRBV6-7 1 0 0 0 1
TRBV7-1 0 0 0 0 0
TRBV7-2 97 12 23 4 49
TRBV7-3 15 2 8 2 6
TRBV7-4 1 0 1 0 0
TRBV7-6 4 0 2 0 7
TRBV7-7 1 0 5 1 3
TRBV7-8 14 1 2 1 6
TRBV7-9 20 4 7 2 32
TRBV9 21 3 10 2 11
TRBV12-4 0 0 0 0 0
TRBV12-3 0 0 0 0 0
TRBV6-3 0 0 0 0 0
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.