I am working on using the SomaticSignatures package on a list of mutations I've received from a collaborator. The file has all the variants listed in a tab-delimited text file, with all the fields you would expect from an annotated vcf file (e.g. Chromosome, Start_Position, End_Position, Reference_Allele, Tumor_Seq_allele, etc) named "CCCC_muts"
In order to get this working, I'm trying to create a VRanges object from this text file. I ran the following command to try to accomplish this:
mutations <- VRanges(
seqnames = seqnames(as.character(CCCC_muts$Chromosome)),
ranges = ranges(CCCC_muts, start = CCCC_muts$Start_Position, end = CCCC_muts$End_Position),
ref = CCCC_muts$Reference_Allele,
alt = CCCC_muts$Tumor_Seq_Allele2,
sampleNames = CCCC_muts$Barcode
I'm getting an error:
Error in (function (classes, fdef, mtable) :
unable to find an inherited method for function ‘ranges’ for signature ‘"X"’
(where X is whatever type of data I try to put into it)
Because I'm unsure how to create the proper ranges format from my CCCC_muts file, and perhaps because of some other reason I don't understand. Any help in resolving this issue would be awesome.