How could I get index file
1
0
Entering edit mode
Fei Liu • 0
@fei-liu-22054
Last seen 2.3 years ago

Hi all,

I'm trying to test ATAC-seq data through ATACseqQC, first download SRR891278, which then transfer to sam file use bwa mem, and then tranfer to bam file use samtools view and samtools sort, but get an error below.

> bamfile <- '/simm/huangyulab/liufei/test/atac-testdata/SRR891278.1.sort.bam'
> bamQC(bamfile, index = '/simm/home/liufei/alignment_exercise/633_hs_genome_hs38d1.fa',outPath='/simm/huangyulab/liufei/test/atac-testdata/test_data/')
    Error in value[[3L]](cond) :
      failed to open BamFile: failed to load BAM index
      file: /simm/home/liufei/alignment_exercise/633_hs_genome_hs38d1.fa

I want to ask how can I get the index file and should that be a bam file?

Thanks

go • 383 views
ADD COMMENT
1
Entering edit mode
@martin-morgan-1513
Last seen 7 days ago
United States

Use Rsamtools::indexBam() or from the command line samtools index ... on your sorted bam file.

ADD COMMENT
0
Entering edit mode

Thank you for the prompt answer.

ADD REPLY

Login before adding your answer.

Traffic: 272 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6