This is a test version of Biostars. For the public version, visit https://www.biostars.org.
bedGrapthToBigWig conversion, xxx is not found in chromosome files

Hi, just try to view the result in USCS browser, and when I tried to convert the bedGraph file to bigwig,

it said xxx is not found in chromosome size file.

I wonder whether it is caused by the naming of the entries by different database,

Is there any tool to convert the ID to USCS IDs?

Thanks

chip-seq
  • 1) what are the names of the cromosomes in the "chromosome size file. "
  • 2 ) what are the names in your bedGraph
  • 3) compare 1 & 2
  • 4) eureka

3 answers

It means that the reference FASTA file you used for alignment and generating bedGraphs is different that the chromosome sizes file.

To generate the chromosome sizes file based on your FASTA file:

samtools faidx genome.fa
cut -f 1,2 genome.fa.fai > chrom.sizes

If I use this chrom.sizes,

Will USCS genome browser work?

Thanks

Yes but only IF you used UCSC's genome sequence to build indexes/align your data.

If I am using the indexes from NCBI to map, what should I do now..

and when I try to use bedGraphToBigWig from USCS to convert bedGraph to bigwig, it complained about

End coordinate xxx bigger than xxx...

What should I do..

If you only want to view your aligned data you can use IGV.

another question,

Why I have "End coordinate xxx bigger than xxx..."

I am using the same genome.fa to build chrom.sizes file and build the indexes and map the reads.

I wonder why I have peaks that outside of the edge of the reference genome.

Thanks

That's usually a sign that you used the wrong genome somewhere. I've only seen that happen when I accidently swappen human and mouse data, for example. I would go back and make sure you used the same one on every step

But I only have human genome on my laptop, does MACS parameter relate to this?

You specify a genome for MACS (by species, not exact FASTA file). I am not sure exactly how it uses that info.

Saying you only have human doesn't mean very much. There are multiple commonly-used and valid human genomes.

Tutorial: bedGraphToBigWig Tutorial and Report

bedGraphToBigWig Tutorial and Report

Due to history, there are small differences in the way that NCBI, EBI and UCSC name the chromosomes. What is "MT" for EBI, can be "chrMT" for NCBI and "chrM" for UCSC. To convert your NCBI to UCSC chrom names, use UCSC's little utility chromToUcsc. Download it with "wget https://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/chromToUcsc", make it executable with "chmod a+x chromToUcsc" and run it without arguments the usage message. Here is an example call: chromToUcsc -g hg19 --get && chromToUcsc -i test.wig -o test.ucsc.wig -a hg19.chromAlias.tsv -g hg19

Log in to answer this question.