Closed nhhaidee closed 1 year ago
General data structure:
Segment virus: samples = ["Sample01", "Sample02", "Sample03"] segments = ["1_PB2", "2_PB1", "3_PA", "4_HA", "5_NP", "7_M", "8_NS"] depths: { 'SAMPLE_NAME':{ 'SEGMENT_NAME': [] // array } } variants: { 'SAMPLE_NAME':{ 'SEGMENT_NAME': {} } } refSeq: { 'SAMPLE_NAME':{ 'SEGMENT_NAME': ref_seq (str) } } refID: { 'SAMPLE_NAME':{ 'SEGMENT_NAME': ref_id (str) } } primerData: { 'SAMPLE_NAME':{ 'SEGMENT_NAME': {} } } Non-segment virus: samples = ["Sample01", "Sample02", "Sample03"] geneFeatureAmpliconData = [{ // use to plot gene feature and amplicon "idx": index, "start": start_pos, "end": end_pos, "level": level, "strand": strand, "type": "gene_feature or amplicon"}] ampliconDepthBarData = [{ // used to plot amplicon bar together with coverage depth chart "value": [start, end, depth, name] "itemStyle": {"color": "skyblue or violet"}}] depths = [ [1, 2, 45, 3, 2, 34, 54, 65, 7, 6, 34, 45, 56, 67, 78, 78], [1, 2, 45, 0, 0, 9, 15, 65, 7, 6, 20, 8, 4, 15, 100, 102], [12, 12, 425, 3, 2, 10, 12, 9, 7, 6, 1, 45, 45, 67, 87, 97] ] // same sample index order as in samples array variants = [ [0:{sample: 'sample1', CHROM: 'MN908947.3',mutation: 'C14408T(orf1ab:L4715L)',POS: 14408}, 1:{sample: 'sample1', CHROM: 'MN908947.3',mutation: 'C14408T(orf1ab:L4715L)',POS: 29300}], [0:{sample: 'sample2', CHROM: 'MN908947.3',mutation: 'C15480A(orf1ab:P5072H)',POS: 10000}, 1:{sample: 'sample2', CHROM: 'MN908947.3',mutation: 'C15480A(orf1ab:P5072H)',POS: 25300}] ] // same sample index order as in samples array
General data structure: