# A complex alteration with 2 subclones (copy numbers 3 and 4). # 2 regions are generated, one for each subclone at 0.8 intra-tumour proportion. # Contamination (i.e. the opposite of tumour purity) is set to 0.5. # Only the 5th element of 'times' is set to 1, meaning that only regions with 2 subclones (5th region type) are included, and once per combination. cnagen( times = c(0,0,0,0, 1, 0), copynumbers = list(NULL,list(c(3,4)),NULL), weights2 = 0.8, purities = 0.5 ) # Possible output regions: # start end proportions copy.numbers homozygosity length main.cn main.cn.prop # 2 1 100 0.5, 0.1, 0.4 2, 3, 4 no 100 4 0.4 # 1 101 200 0.5, 0.4, 0.1 2, 3, 4 no 100 3 0.4 # ------------------- # ------------------- # 3 simple CNA regions of different lengths and copy number 3. cnagen( lengths = list(NULL, c(10,20,50), NULL,NULL,NULL,NULL), times = c(0, 1, 0,0,0,0), copynumbers = list(list(c(3)),NULL,NULL), purities = 1 ) # Possible output regions: # start end proportions copy.numbers homozygosity length main.cn main.cn.prop # 2 1 20 0, 1 2, 3 no 20 3 1 # 3 21 70 0, 1 2, 3 no 50 3 1 # 1 71 80 0, 1 2, 3 no 10 3 1 # ------------------- # ------------------- # 2 normal diploid region of 50 and 100 SNPs and 2 somatic LOH regions (copy numbers 1 and 3) of 10 SNPs repeated twice each. cnagen( lengths = list(c(50,100), NULL, c(10), NULL,NULL,NULL), times = c(1, 0, 2, 0,0,0), copynumbers = list(list(c(1),c(3)),NULL,NULL), purities = 0.2 ) # Possible output regions: # start end proportions copy.numbers homozygosity length main.cn main.cn.prop # 1 1 50 1 2 no 50 2 1.0 # 3 51 60 0.8, 0.2 2, 3 somatic 10 3 0.2 # 2 61 70 0.8, 0.2 2, 1 somatic 10 1 0.2 # 5 71 80 0.8, 0.2 2, 3 somatic 10 3 0.2 # 4 81 90 0.8, 0.2 2, 1 somatic 10 1 0.2 # 6 91 190 1 2 no 100 2 1.0