htslib icon indicating copy to clipboard operation
htslib copied to clipboard

User Guide

Open danielecook opened this issue 9 years ago • 6 comments

Is there a user guide / documentation for htslib?

danielecook avatar Jul 22 '14 14:07 danielecook

There is at present nothing beyond the (rather incomplete) API documentation inline in the header files.

(And what can be gleaned by considering the samtools and bcftools code as "sample code".)

jmarshall avatar Jul 22 '14 14:07 jmarshall

Thanks. I'll see what I can pick up.

danielecook avatar Jul 22 '14 15:07 danielecook

I started using htslib to read/manipulate BAM files a few days ago and I second that there should be more documentation.

I can see that this is boring work and that documentation often diverges from the code, which is why in-code documentation has its advantages. However, the in-code documentation is often incomplete or completely missing (at least for the BAM part). Thus, I advocate for some example programs that read/write data to illustrate the most common use-cases. The example programs would be buildable/testable, so it's easy to keep them up-to-date.

For BAM files I would have hoped for these examples:

  • read and print the file header and alignments
  • manipulate the file header and alignments (including bases, qualities, CIGAR, ...)

imgag avatar Mar 21 '18 11:03 imgag

Started using htslib myself some months ago and still find it difficult to find usage of some parts of it. It makes development more time consuming and error prone.

rulixxx avatar Dec 08 '20 14:12 rulixxx

@rulixxx We are quite aware of this aspect and we are planning to invest more resources in the documentation and the user guide. In the meantime, can you describe your use case and see how we can assist you? You can use [email protected], if you don't want to post it here.

valeriuo avatar Dec 08 '20 15:12 valeriuo

Yes I was aware that this is a common complaint of users. I just wanted to add my grain of sand to addressing the issue (not just complain and forget about it).

Thanks for your offer Valeriu. Thus far I have been able to get by looking at examples, header files and generated pages. My most recent problem was hunting down the return codes for several functions from htslib in order to harden a piece of code. I had to jump from headers to various documents in order to get the full picture for each function (not really sure Im looking at the most adequate/ updated source in the web). I just thought it would save time having all of it in one place with a simple navigation inferface...


From: Valeriu Ohan [email protected] Sent: Tuesday, December 8, 2020 4:08 PM To: samtools/htslib [email protected] Cc: Raul Alcantara [email protected]; Mention [email protected] Subject: Re: [samtools/htslib] User Guide (#114)

@rulixxxhttps://github.com/rulixxx We are quite aware of this aspect and we are planning to invest more resources in the documentation and the user guide. In the meantime, can you describe your use case and see how we can assist you? You can use [email protected]mailto:[email protected], if you don't want to post it here.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/samtools/htslib/issues/114#issuecomment-740675918, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AEAAUCEM7KHFTXZKTNWXCNLSTY6NRANCNFSM4AR6DJ2A.

rulixxx avatar Dec 08 '20 17:12 rulixxx