inst/extdata/motrpac_colors_abbr.R

# Motrpac colors abbreviations

library(dplyr)
library(devtools)

assay_abbr = c(atac='ATAC',
               atacseq='ATAC',
               'atac-seq'='ATAC',
               'epigen-atac-seq'='ATAC',
               rrbs='METHYL',
               'epigen-rrbs'='METHYL',
               rnaseq='TRNSCRPT',
               'rna-seq'='TRNSCRPT',
               'transcript-rna-seq'='TRNSCRPT',
               'transcript-rna-seq-splice'='SPLICE',
               altsplice='SPLICE',
               metabolomics='METAB',
               'metab'='METAB',
               'metab-meta'='METAB',
               'unnamed-metab'='U-METAB',
               'named-metab'='N-METAB',
               'prot-pr'='PROT',
               'prot-ac'='ACETYL',
               'prot-ph'='PHOSPHO',
               'prot-ub'='UBIQ',
               'prot-ub-protein-corrected'='UBIQ',
               'immunoassay'='IMMUNO')

use_data(assay_abbr, overwrite = TRUE)

assay_order = c('METHYL',
                'ATAC',
                'TRNSCRPT',
                'PROT',
                'PHOSPHO',
                'ACETYL',
                'UBIQ',
                'IMMUNO',
                'N-METAB',
                'U-METAB',
                'METAB')

use_data(assay_order, overwrite = TRUE)

group_abbr = c('control'='SED',
               'control8w'='SED',
               '0w'='SED',
               '1w'='1W',
               '2w'='2W',
               '4w'='4W',
               '8w'='8W')

use_data(group_abbr, overwrite = TRUE)

group_cols = c('SED'='white',
               'control'='white',
               '0w' = 'white',
               '0W' = 'white',
               '1W' = '#F7FCB9',
               '1w' = '#F7FCB9',
               '2W' = '#ADDD8E',
               '2w' = '#ADDD8E',
               '4W' = '#238443',
               '4w' = '#238443',
               '8W' = '#002612',
               '8w' = '#002612')

use_data(group_cols, overwrite = TRUE)

sex_abbr = c('female'='F',
             'Female'='F',
             'male'='M',
             'Male'='M')

use_data(sex_abbr, overwrite = TRUE)

sex_cols = c('M' = '#5555ff',
             'Male' = '#5555ff',
             'male' = '#5555ff',
             'F' = '#ff6eff',
             'Female' = '#ff6eff',
             'female' = '#ff6eff')

use_data(sex_cols, overwrite = TRUE)

tissue_abbr = c(adrenals='ADRNL',
                adrenal='ADRNL',
                't60-adrenal'='ADRNL',
                aorta='VENACV',
                'vena-cava'='VENACV',
                'vena cava'='VENACV',
                't65-aorta'='VENACV',
                't99-vena-cava'='VENACV',
                'brown-adipose'='BAT',
                'brown adipose'='BAT',
                't69-brown-adipose'='BAT',
                colon='COLON',
                't61-colon'='COLON',
                cortex='CORTEX',
                't53-cortex'='CORTEX',
                plasma='PLASMA',
                'edta plasma'='PLASMA',
                't31-plasma'='PLASMA',
                gastrocnemius='SKM-GN',
                't55-gastrocnemius'='SKM-GN', 
                heart='HEART',
                't58-heart'='HEART',
                hippocampus='HIPPOC',
                't52-hippocampus'='HIPPOC',
                hypothalmus='HYPOTH',
                hypothalamus='HYPOTH',
                't54-hypothalamus'='HYPOTH',
                kidney='KIDNEY',
                't59-kidney'='KIDNEY',
                liver='LIVER',
                't68-liver'='LIVER',
                lung='LUNG',
                't66-lung'='LUNG',
                ovaries='OVARY',
                't64-ovaries'='OVARY',
                'blood-rna'='BLOOD',
                'blood rna'='BLOOD',
                'paxgene rna'='BLOOD',
                'paxgene-rna'='BLOOD',
                't30-blood-rna'='BLOOD',
                'small-intestine'='SMLINT',
                'small intestine'='SMLINT',
                't67-small-intestine'='SMLINT',
                spleen='SPLEEN',
                't62-spleen'='SPLEEN',
                testes='TESTES',
                't63-testes'='TESTES',
                spleen='SPLEEN',
                't62-spleen'='SPLEEN',
                'vastus-lateralis'='SKM-VL',
                'vastus lateralis'='SKM-VL',
                't56-vastus-lateralis'='SKM-VL',
                'white-adipose'='WAT-SC',
                'white adipose'='WAT-SC',
                't70-white-adipose'='WAT-SC',
                lateralgastroc = 'SKM-LG',
                'lateral-gastroc' = 'SKM-LG',
                'lateral gastrocnemius' = 'SKM-LG',
                'Lateral Gastrocnemius' = 'SKM-LG',
                'lateral-gastrocnemius' = 'SKM-LG'
                )

use_data(tissue_abbr, overwrite = TRUE)

tissue_cols = c('paxgene rna'='#d92c04', # blood and paxgene rna are the same (RNA-seq)
                'paxgene-rna'='#d92c04',
                'paxgene_rna'='#d92c04',
                blood='#d92c04',
                'blood rna'='#d92c04',
                'blood-rna'='#d92c04',
                'blood_rna'='#d92c04',
                BLOOD='#d92c04',
                't30-blood-rna'='#d92c04',
                'edta plasma'='#f1997c',
                'edta-plasma'='#f1997c',
                'edta_plasma'='#f1997c',
                plasma='#f1997c',
                PLASMA='#f1997c',
                't31-plasma'='#f1997c', 
                heart='#f28b2f',
                HEART='#f28b2f',
                't58-heart'='#f28b2f',
                aorta='#a5415b',
                'vena cava'='#a5415b',
                'vena-cava'='#a5415b',
                'vena_cava'='#a5415b',
                VENACV='#a5415b',
                't65-aorta'='#a5415b',
                't99-vena-cava'='#a5415b',
                spleen='#f3c288',
                SPLEEN='#f3c288',
                't62-spleen'='#f3c288',
                gastrocnemius='#088c03',
                'SKM-GN'='#088c03',
                't55-gastrocnemius'='#088c03',
                'vastus lateralis'='#025939',
                'vastus-lateralis'='#025939',
                'vastus_lateralis'='#025939',
                'SKM-VL'='#025939',
                't56-vastus-lateralis'='#025939',
                'SKM-LG' = '#025950',
                lateralgastroc = '#025950',
                't77-lateral-gastroc' = '#025950',
                'lateral-gastrocnemius' = '#025950',
                'lateral gastrocnemius' = '#025950',
                'white adipose'='#214da6',
                'white-adipose'='#214da6',
                'white_adipose'='#214da6',
                'WAT-SC'='#214da6',
                't70-white-adipose'='#214da6',
                'brown adipose'='#8c5220',
                'brown-adipose'='#8c5220',
                'brown_adipose'='#8c5220',
                'BAT'='#8c5220',
                't69-brown-adipose'='#8c5220',
                liver='#da6c75',
                LIVER='#da6c75',
                't68-liver'='#da6c75',
                lung='#04bf8a',
                LUNG='#04bf8a',
                't66-lung'='#04bf8a',
                kidney='#7553a7',
                KIDNEY='#7553a7',
                't59-kidney'='#7553a7', 
                adrenal='#DDA0DD',
                adrenals='#DDA0DD',
                ADRNL='#DDA0DD',
                't60-adrenal'='#DDA0DD',
                cortex='#f2e751',
                CORTEX='#f2e751',
                't53-cortex'='#f2e751', 
                hypothalamus='#f2b443',
                HYPOTH='#f2b443',
                hypothalmus='#f2b443',
                't54-hypothalamus'='#f2b443',
                hippocampus='#bf7534',
                HIPPOC='#bf7534',
                't52-hippocampus'='#bf7534',
                'small intestine'='#A18277',
                'small-intestine'='#A18277',
                'small_intestine'='#A18277',
                'SMLINT'='#A18277',
                't67-small-intestine'='#A18277',
                colon='#5a2e15',
                COLON='#5a2e15',
                't61-colon'='#5a2e15',
                ovaries='#f2ced0',
                OVARY='#f2ced0',
                't64-ovaries'='#f2ced0',
                testes='#6d86a5',
                TESTES='#6d86a5',
               't63-testes'='#6d86a5')

use_data(tissue_cols, overwrite = TRUE)

tissue_order = c('BLOOD',
                 'PLASMA',
                 'HEART',
                 'VENACV',
                 'SPLEEN',
                 'SKM-GN',
                 'SKM-VL',
                 'SKM-LG',
                 'WAT-SC',
                 'BAT',
                 'LIVER',
                 'LUNG',
                 'KIDNEY',
                 'ADRNL',
                 'CORTEX',
                 'HYPOTH',
                 'HIPPOC',
                 'SMLINT',
                 'COLON',
                 'OVARY',
                 'TESTES')

use_data(tissue_order, overwrite = TRUE)
MoTrPAC/MotrpacBicQC documentation built on Sept. 26, 2024, 11:10 a.m.