Hi,
I am using Varscan2 to call CNV in tumor-normal samples. After the first two steps, an output.copynumber file and copynumber.called file have been generated.
Then I followed the protocol to use the DNAcopy package to do the CBS segmentation,
My command line is as follows:
library(DNAcopy) cn<-read.table("output.copynumber",header=F) CNA.object <-CNA( genomdat = cn[,6], chrom = cn[,1], maploc = cn[,2], data.type = 'logratio')
But I got the error :
Error in CNA(genomdat = cn[, 6], chrom = cn[, 1], maploc = cn[, 2], data.type = "logratio") :
genomdat must be numeric
But the data in the coloum 6 of "output.copynumber" are all decimal numbers, so I am confused why I got this error?
Could anybody gave me some suggestions?
Thank you for your time.
I was running the following command :
library(DNAcopy)
read.table <- function(file=x,header=FALSE,use.value.labels=TRUE,to.data.frame=TRUE,sep=",", widths=rep(1,36),f=NULL, filetype=tableau,...)
cn <- read.table(correct_copy), header=F)
CNA.object <-CNA( genomdat = as.numeric(cn[,36]), chrom = as.numeric(cn[,36]), maploc = as.numeric(cn[,36]), data.type = 'logratio',sampleid = "E47") ## as.numeric(cn[,36])
and I get rror: unexpected ',' in: " widths=rep(1,36),f=NULL, filetype=tableau,...) cn <- read.table(correct_copy),"