This is my code line:
##CODEX2 TEST- 09/07
#Pre-processing
library(CODEX2)
#library(WES.1KG.WUGSC) # Load Toy data from the 1000 Genomes Project.
dirPath <- "/home/scratch60/ramon_CODEX/bams"
bamFile <- list.files(dirPath, pattern = '101.sorted.q30.dedup.bam$')
bamdir <- file.path(dirPath, bamFile)
sampname <- substr(bamFile,1,7)
bedFile <- file.path ("/home/scratch60/ramon_CODEX/reference/S06588914_Regions-hg38.main.bed")
bambedObj <- getbambed(bamdir = bamdir, bedFile = bedFile,
sampname = sampname, projectname = "CODEX2_bcg")
bamdir <- bambedObjbamdir;sampname<−bambedObjbamdir;sampname<−bambedObjsampname
ref <- bambedObjref;projectname<−bambedObjref;projectname<−bambedObjprojectname
The other parts of the code remais unchanged and I am using only one BAM file and it's respective BAI file.