# NOT RUN {
bam<-system.file("extdata","accepted_hits.bam",package="rbamtools")
idx<-paste(bam,"bai",sep=".")
# Open BAM file
reader<-bamReader(bam)
header<-getHeader(reader)
htxt<-getHeaderText(header)
getHeaderText(htxt)
bamClose(reader)
# }
Run the code above in your browser using DataLab