Learn R Programming

maftools (version 0.99.30)

oncotate: Annotates given variants using oncotator api.

Description

Takes variants as input and annotates them using Broad's oncotator api (http://www.broadinstitute.org/oncotator/). Output is a dataframe of annotated variants in maf format.

Input should be a five column file with chr, start, end, ref_allele, alt_allele (and so on, but only first five will used, rest will be attached to resulting maf file). Note: Time consuming if input is huge. Try to include necessary columns such as Tumor_Sample_Barcode along with above 5 fields.

Usage

oncotate(maflite, header = FALSE, basename = NULL)

Arguments

maflite

input tsv file with chr, start, end, ref_allele, alt_allele columns. (rest of the columns, if present will be attached to the output maf)

header

logical. Whether input has a header line. Default is FALSE.

basename

NULL. if basename is given, annotations will be written to <basename>.maf file.

Value

returns a dataframe in maf format.

Examples

Run this code
# NOT RUN {
sample.var = data.frame(chromsome = c('chr4', 'chr15'), Start = c(55589774, 41961117),
end = c(55589774, 41961117), ref = c('A', 'TGGCTAA'), alt = c('G', '-'),
Tumor_Sample_Barcode = c('fake_1', 'fake2'))
write.table(sample.var, 'sampleVars.txt', sep='\t',quote = FALSE, row.names = FALSE)
##var.maf <- oncotate(maflite = 'sampleVars.txt', header = TRUE)
# }

Run the code above in your browser using DataLab