OutputsharedPro {customProDB} | R Documentation |
Output a FASTA file containing shared proteins with expression above cutoff in multiple samples
OutputsharedPro(RPKMs, cutoff = "30%", share_sample = "50%", proteinseq, outfile, ids, ...)
RPKMs |
RPKM matrix; row name (protein name) is required. |
cutoff |
a percentage format cutoff (e.g. '30 a vector with each element as a vlaue cutoff referring to one sample |
share_sample |
the minimum share sample numbers for proteins which pass the cutoff. |
proteinseq |
a dataframe containing protein ids and protein sequences |
outfile |
output file name |
ids |
a dataframe containing gene/transcript/protein id mapping information. |
... |
additional arguments |
this function takes RPKM matrix as input, users can set two paramteters,cutoff and shared, to generated a consensus expressed database
a FASTA file containing proteins with RPKM above the cutoff in at least certain number of samples
Xiaojing Wang
path <- system.file("extdata/bams", package="customProDB") load(system.file("extdata/refseq", "exon_anno.RData", package="customProDB")) load(system.file("extdata/refseq", "proseq.RData", package="customProDB")) load(system.file("extdata/refseq", "ids.RData", package="customProDB")) bamFile<- paste(path, '/', list.files(path, pattern="*bam$"), sep='') rpkms <- sapply(bamFile,function(x) calculateRPKM(x, exon, proteincodingonly=TRUE, ids)) outfile <- paste(tempdir(), '/test_rpkm_share.fasta', sep='') OutputsharedPro(rpkms, cutoff=1, share_sample=2, proteinseq, outfile, ids)