For an input dataset merge all the events of two or more distincit types (e.g., say that missense and indel mutations are events of a unique "mutation" type)
join.types(x, ..., new.type = "new.type", new.color = "khaki", silent = FALSE)
A TRONCO compliant dataset.
data(test_dataset_no_hypos)
join.types(test_dataset_no_hypos, 'ins_del', 'missense_point_mutations')
#> *** Aggregating events of type(s) { ins_del, missense_point_mutations }
#> in a unique event with label " new.type ".
#> Dropping event types ins_del, missense_point_mutations for 19 genes.
#> ...................
#> *** Binding events for 2 datasets.
#> $genotypes
#> G1 G2 G3 G4 G5 G6 G7 G8 G9 G10 G11 G12 G13 G14 G15 G16 G17 G18 G19
#> patient 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 2 0 0 0 0 0 1 0 0 0 0 1 0 0 1 0 0 0 0 0
#> patient 3 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0
#> patient 4 0 0 0 0 0 1 0 0 0 0 1 0 0 1 0 0 0 0 0
#> patient 5 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 6 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 7 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 8 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 9 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0
#> patient 10 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 11 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 12 0 0 0 1 0 0 0 0 0 0 1 1 0 0 0 0 1 0 0
#> patient 13 0 0 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 14 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 15 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0
#> patient 16 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 17 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0
#> patient 18 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 19 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 20 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0
#> patient 21 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0
#> patient 22 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0
#> patient 23 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0
#> patient 24 0 0 0 0 0 0 0 1 1 1 0 0 0 1 0 0 0 0 0
#> patient 25 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0
#> patient 26 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 27 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0
#> patient 28 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 29 0 0 0 1 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0
#> patient 30 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 31 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0
#> patient 32 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0
#> patient 33 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 34 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0
#> patient 35 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 36 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 37 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 38 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1
#> patient 39 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0
#> patient 40 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> G20 G21 G22 G23 G24 G25 G26
#> patient 1 0 0 0 0 0 0 0
#> patient 2 0 0 0 0 0 0 0
#> patient 3 0 0 0 0 0 0 0
#> patient 4 0 0 0 0 0 0 0
#> patient 5 0 0 0 0 0 1 0
#> patient 6 0 0 0 0 0 0 0
#> patient 7 1 0 0 0 0 0 0
#> patient 8 0 0 0 0 0 0 0
#> patient 9 0 0 0 0 0 0 0
#> patient 10 0 0 0 0 0 0 0
#> patient 11 0 0 0 0 0 0 0
#> patient 12 0 0 0 0 0 0 0
#> patient 13 0 0 0 0 0 1 0
#> patient 14 0 0 0 0 0 0 0
#> patient 15 0 0 0 0 0 0 0
#> patient 16 0 0 0 0 1 0 0
#> patient 17 0 0 0 1 0 0 0
#> patient 18 0 0 0 0 0 0 0
#> patient 19 0 0 1 0 0 0 0
#> patient 20 0 1 0 0 0 0 0
#> patient 21 0 0 0 0 0 0 0
#> patient 22 0 0 0 0 0 0 0
#> patient 23 0 0 0 0 0 0 1
#> patient 24 0 0 0 0 0 0 0
#> patient 25 0 0 0 0 0 0 1
#> patient 26 0 0 0 0 0 0 0
#> patient 27 0 0 0 0 0 0 0
#> patient 28 0 0 0 0 0 0 0
#> patient 29 0 0 0 0 0 0 0
#> patient 30 0 0 0 0 0 1 0
#> patient 31 0 0 0 0 0 0 0
#> patient 32 0 0 0 0 0 0 0
#> patient 33 0 0 0 0 0 0 0
#> patient 34 0 0 0 0 0 1 0
#> patient 35 0 0 0 0 0 0 0
#> patient 36 0 0 0 0 0 0 0
#> patient 37 0 0 0 0 0 0 0
#> patient 38 0 0 0 0 0 0 0
#> patient 39 0 0 0 0 0 0 0
#> patient 40 0 0 0 0 0 0 0
#>
#> $annotations
#> type event
#> G1 "nonsense_ins_del" "WT1"
#> G2 "nonsense_ins_del" "RUNX_1"
#> G3 "nonsense_ins_del" "CEBPA"
#> G4 "nonsense_point_mutations" "TET2"
#> G5 "nonsense_point_mutations" "EZH2"
#> G6 "nonsense_point_mutations" "ASXL1"
#> G7 "nonsense_point_mutations" "CSF3R"
#> G8 "new.type" "TET2"
#> G9 "new.type" "EZH2"
#> G10 "new.type" "ASXL1"
#> G11 "new.type" "SETBP1"
#> G12 "new.type" "NRAS_Ex2_3"
#> G13 "new.type" "KRAS_Ex2_3"
#> G14 "new.type" "CBL_Ex_8_9"
#> G15 "new.type" "IDH2_R140"
#> G16 "new.type" "SF3B1_Ex_12_15"
#> G17 "new.type" "JARID_2_Ex1_18"
#> G18 "new.type" "EED_Ex2_12"
#> G19 "new.type" "CEBPA"
#> G20 "new.type" "EPHB3"
#> G21 "new.type" "ETNK1"
#> G22 "new.type" "GATA2"
#> G23 "new.type" "IRAK4"
#> G24 "new.type" "MTA2"
#> G25 "new.type" "CSF3R"
#> G26 "new.type" "KIT"
#>
#> $types
#> color
#> nonsense_ins_del "cornflowerblue"
#> nonsense_point_mutations "firebrick1"
#> new.type "khaki"
#>
join.types(test_dataset_no_hypos, 'ins_del',
'missense_point_mutations', new.type='mut', new.color='green')
#> *** Aggregating events of type(s) { ins_del, missense_point_mutations }
#> in a unique event with label " mut ".
#> Dropping event types ins_del, missense_point_mutations for 19 genes.
#> ...................
#> *** Binding events for 2 datasets.
#> $genotypes
#> G1 G2 G3 G4 G5 G6 G7 G8 G9 G10 G11 G12 G13 G14 G15 G16 G17 G18 G19
#> patient 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 2 0 0 0 0 0 1 0 0 0 0 1 0 0 1 0 0 0 0 0
#> patient 3 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0
#> patient 4 0 0 0 0 0 1 0 0 0 0 1 0 0 1 0 0 0 0 0
#> patient 5 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 6 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 7 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 8 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 9 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0
#> patient 10 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 11 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 12 0 0 0 1 0 0 0 0 0 0 1 1 0 0 0 0 1 0 0
#> patient 13 0 0 0 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 14 0 0 0 0 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0
#> patient 15 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0
#> patient 16 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 17 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0
#> patient 18 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 19 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 20 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0
#> patient 21 0 0 0 0 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0
#> patient 22 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0
#> patient 23 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0
#> patient 24 0 0 0 0 0 0 0 1 1 1 0 0 0 1 0 0 0 0 0
#> patient 25 0 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0
#> patient 26 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 27 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0
#> patient 28 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 29 0 0 0 1 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0
#> patient 30 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 31 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0
#> patient 32 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0
#> patient 33 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 34 1 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0
#> patient 35 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 36 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 37 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> patient 38 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 1
#> patient 39 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0
#> patient 40 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
#> G20 G21 G22 G23 G24 G25 G26
#> patient 1 0 0 0 0 0 0 0
#> patient 2 0 0 0 0 0 0 0
#> patient 3 0 0 0 0 0 0 0
#> patient 4 0 0 0 0 0 0 0
#> patient 5 0 0 0 0 0 1 0
#> patient 6 0 0 0 0 0 0 0
#> patient 7 1 0 0 0 0 0 0
#> patient 8 0 0 0 0 0 0 0
#> patient 9 0 0 0 0 0 0 0
#> patient 10 0 0 0 0 0 0 0
#> patient 11 0 0 0 0 0 0 0
#> patient 12 0 0 0 0 0 0 0
#> patient 13 0 0 0 0 0 1 0
#> patient 14 0 0 0 0 0 0 0
#> patient 15 0 0 0 0 0 0 0
#> patient 16 0 0 0 0 1 0 0
#> patient 17 0 0 0 1 0 0 0
#> patient 18 0 0 0 0 0 0 0
#> patient 19 0 0 1 0 0 0 0
#> patient 20 0 1 0 0 0 0 0
#> patient 21 0 0 0 0 0 0 0
#> patient 22 0 0 0 0 0 0 0
#> patient 23 0 0 0 0 0 0 1
#> patient 24 0 0 0 0 0 0 0
#> patient 25 0 0 0 0 0 0 1
#> patient 26 0 0 0 0 0 0 0
#> patient 27 0 0 0 0 0 0 0
#> patient 28 0 0 0 0 0 0 0
#> patient 29 0 0 0 0 0 0 0
#> patient 30 0 0 0 0 0 1 0
#> patient 31 0 0 0 0 0 0 0
#> patient 32 0 0 0 0 0 0 0
#> patient 33 0 0 0 0 0 0 0
#> patient 34 0 0 0 0 0 1 0
#> patient 35 0 0 0 0 0 0 0
#> patient 36 0 0 0 0 0 0 0
#> patient 37 0 0 0 0 0 0 0
#> patient 38 0 0 0 0 0 0 0
#> patient 39 0 0 0 0 0 0 0
#> patient 40 0 0 0 0 0 0 0
#>
#> $annotations
#> type event
#> G1 "nonsense_ins_del" "WT1"
#> G2 "nonsense_ins_del" "RUNX_1"
#> G3 "nonsense_ins_del" "CEBPA"
#> G4 "nonsense_point_mutations" "TET2"
#> G5 "nonsense_point_mutations" "EZH2"
#> G6 "nonsense_point_mutations" "ASXL1"
#> G7 "nonsense_point_mutations" "CSF3R"
#> G8 "mut" "TET2"
#> G9 "mut" "EZH2"
#> G10 "mut" "ASXL1"
#> G11 "mut" "SETBP1"
#> G12 "mut" "NRAS_Ex2_3"
#> G13 "mut" "KRAS_Ex2_3"
#> G14 "mut" "CBL_Ex_8_9"
#> G15 "mut" "IDH2_R140"
#> G16 "mut" "SF3B1_Ex_12_15"
#> G17 "mut" "JARID_2_Ex1_18"
#> G18 "mut" "EED_Ex2_12"
#> G19 "mut" "CEBPA"
#> G20 "mut" "EPHB3"
#> G21 "mut" "ETNK1"
#> G22 "mut" "GATA2"
#> G23 "mut" "IRAK4"
#> G24 "mut" "MTA2"
#> G25 "mut" "CSF3R"
#> G26 "mut" "KIT"
#>
#> $types
#> color
#> nonsense_ins_del "cornflowerblue"
#> nonsense_point_mutations "firebrick1"
#> mut "green"
#>