Learn R Programming

mglR (version 0.1.0)

makeCoXpGene: Tests pairwise co-expression for normalized expression data

Description

makeCoXpGene returns a list of cor.test output for each user-defined gene pair in a given tissue

Usage

makeCoXpGene(mgl, genes = c(), makePlot = FALSE, saveFile = FALSE, data = c(7, 8, 10), tissue = c("All", "Adipose - Subcutaneous", "Adipose - Visceral (Omentum)", "Adrenal Gland", "Artery - Aorta", "Artery - Coronary", "Artery - Tibial", "Bladder", "Brain - Amygdala", "Brain - Anterior cingulate cortex (BA24)", "Brain - Caudate (basal ganglia)", "Brain - Cerebellar Hemisphere", "Brain - Cerebellum", "Brain - Cortex", "Brain - Frontal Cortex (BA9)", "Brain - Hippocampus", "Brain - Hypothalamus", "Brain - Nucleus accumbens (basal ganglia)", "Brain - Putamen (basal ganglia)", "Brain - Spinal cord (cervical c-1)", "Brain - Substantia nigra", "Breast - Mammary Tissue", "Cells - EBV-transformed lymphocytes", "Cells - Transformed fibroblasts", "Cervix - Ectocervix", "Cervix - Endocervix", "Colon - Sigmoid", "Colon - Transverse", "Esophagus - Gastroesophageal Junction", "Esophagus - Mucosa", "Esophagus - Muscularis", "Fallopian Tube", "Heart - Atrial Appendage", "Heart - Left Ventricle", "Kidney - Cortex", "Liver", "Lung", "Minor Salivary Gland", "Muscle - Skeletal", "Nerve - Tibial", "Ovary", "Pancreas", "Pituitary", "Prostate", "Skin - Not Sun Exposed (Suprapubic)", "Skin - Sun Exposed (Lower leg)", "Small Intestine - Terminal Ileum", "Spleen", "Stomach", "Testis", "Thyroid", "Uterus", "Vagina", "Whole Blood"))

Arguments

genes
Character vector indicating genes to be considered (note gene names must match names(mgl))
makePlot
Logical flag - TRUE indicates pdf file named 'CoXpGene.pdf' will be saved in the current directory
saveFile
Logical flag - TRUE indicates csv file named 'CoXpGene.csv' will be saved in the current directory. 'CoXpGene.csv' contains cor.test results
data
Number corresponding to element of mgl containing data of interest: 8 for count data and 10 for RPKM
tissue
Character vector indicating tissues to be considered (note tissue names must match those provided here: c('All', Adipose - Subcutaneous', 'Adipose - Visceral (Omentum)', 'Adrenal Gland', 'Artery - Aorta', 'Artery - Coronary', 'Artery - Tibial', 'Bladder', 'Brain - Amygdala', 'Brain - Anterior cingulate cortex (BA24)', 'Brain - Caudate (basal ganglia)', 'Brain - Cerebellar Hemisphere', 'Brain - Cerebellum', 'Brain - Cortex', 'Brain - Frontal Cortex (BA9)', 'Brain - Hippocampus', 'Brain - Hypothalamus', 'Brain - Nucleus accumbens (basal ganglia)', 'Brain - Putamen (basal ganglia)', 'Brain - Spinal cord (cervical c-1)', 'Brain - Substantia nigra', 'Breast - Mammary Tissue', 'Cells - EBV-transformed lymphocytes', 'Cells - Transformed fibroblasts', 'Cervix - Ectocervix', 'Cervix - Endocervix', 'Colon - Sigmoid', 'Colon - Transverse', 'Esophagus - Gastroesophageal Junction', 'Esophagus - Mucosa', 'Esophagus - Muscularis', 'Fallopian Tube', 'Heart - Atrial Appendage', 'Heart - Left Ventricle', 'Kidney - Cortex', 'Liver', 'Lung', 'Minor Salivary Gland', 'Muscle - Skeletal', 'Nerve - Tibial', 'Ovary', 'Pancreas', 'Pituitary', 'Prostate', 'Skin - Not Sun Exposed (Suprapubic)', 'Skin - Sun Exposed (Lower leg)', 'Small Intestine - Terminal Ileum', 'Spleen', 'Stomach', 'Testis', 'Thyroid', 'Uterus', 'Vagina', 'Whole Blood'))

Details

Uses the cor.test function in R to test for co-expression between genes. Option to generate scatter plots and a summary table of the correlations to be saved as a pdf and csv, respectively. Any number of genes and tissues can be included. Normalized (data = 7), counts (data = 8), or RPKM (data = 10) can be used.

See Also

Other output: makeAeiPlot, makeCoXpTranscript, makeDnaseSig, makeGoSearch, makeGo, makeMultiEqtl, makeOverlapTable, makeOverlap, makePhenotypeSearch, makePhenotypes, makeSnpSearch, makeSnps, makeSummary

Examples

Run this code
exMgl() -> myMgl
makeCoXpGene(myMgl, gene = c('RP11-109G10.2', 'NCOA4'), makePlot = FALSE, 
    saveFile = FALSE, data = 7, tissue = c('Prostate')) -> results

Run the code above in your browser using DataLab