This is a test version of Biostars. For the public version, visit https://www.biostars.org.
index a large file to get lines faster

I wonder if a bash tool exist to index a text file composed of different line length. For example, Line number x will be associated to the bytes y and the length z! Then it will be faster to get the line using byte pointer like file.seek or dd bash command.

large-file seek index

Hello sacha!

We believe that this post does not fit the main topic of this site.

This sounds like a pure programming question that might fit better on stackoverflow. If you have a specific bioinformatics data type in mind please add to question.

For this reason we have closed your question. This allows us to keep the site focused on the topics that the community can help with.

If you disagree please tell us why in a reply below, we'll be happy to talk about it.

Cheers!

1 answer

It seems tabix do the job for vcf, sam, gff, and bed! So It's not a general tool as I suggest, but it's perfect for my need!

Log in to answer this question.