Seqanswers Leaderboard Ad

Collapse

Announcement

Collapse
No announcement yet.
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • tabix error on Mac

    In the course of getting VCF tools running on Mac (OSX), I stumbled upon what appears to be a Mac-specific problem with tabix. The VCFtools merge-vcf perl script calls tabix <filename.vcf> -l . The '-l' option is not listed in the tabix manual document, but it is supposed to list the sequence names stored in the index of the bgzipped vcf file that gets created via 'tabix -p vcf <filename.vcf.gz>' . Whether running merge-vcf or running tabix directly on the bgzipped versions of the VCFtools example files (as well as on my own data), on a Mac I get the following error:

    '[main] invalid region: unknown target name or minus interval.'

    But, when I run the same exact commands on a Linux machine....everything works fine, no errors at all.

    No related posts to date as far as I can tell, but is anyone else aware of this issue, and is there any plan to correct it in the future?
    Adam H. Freedman
    Dept. of OEB, Harvard University

  • #2
    Try changing the perl script from calling this:

    tabix <filename.vcf> -l

    to call this instead:

    tabix -l <filename.vcf>

    Comment


    • #3
      thanks. didn't change the perl script yet, but, yes, running tabix -l <filename> on the command line instead of tabix <filename> -l solves the problem. very odd behavior on the Mac's part though...or perhaps it is more accurate to say better behavior on Linux's part.
      Adam H. Freedman
      Dept. of OEB, Harvard University

      Comment


      • #4
        Tabix parses its command line options with getopt(). On Linux, you get GNU getopt() which, as a convenient extension to the standard behaviour, accepts options intermixed with arguments such as filenames. On Mac OS, unless you take steps to compile tabix with GNU getopt() yourself, you get the standard behaviour -- which doesn't.

        Taking advantage of this non-portable extension is a wee bug in vcftools's Vcf.pm (and also vcf-isec), and I've pointed Petr at this thread, so hopefully it'll get fixed in svn soon. (And in the meantime, as maubp showed, it's not too hard to patch it yourself )

        -- John

        Comment


        • #5
          Originally posted by adamhfreedman View Post
          thanks. didn't change the perl script yet, but, yes, running tabix -l <filename> on the command line instead of tabix <filename> -l solves the problem. very odd behavior on the Mac's part though...or perhaps it is more accurate to say better behavior on Linux's part.
          Yes, this annoys me regularly (e.g. "ls *.py -l" has to be typed as "ls -l *.py"). This is a Mac OS X design choice that affects command line parsing [although there are workarounds, see John's post above].
          Last edited by maubp; 10-26-2010, 12:52 AM. Reason: Correction

          Comment

          Latest Articles

          Collapse

          • seqadmin
            Strategies for Sequencing Challenging Samples
            by seqadmin


            Despite advancements in sequencing platforms and related sample preparation technologies, certain sample types continue to present significant challenges that can compromise sequencing results. Pedro Echave, Senior Manager of the Global Business Segment at Revvity, explained that the success of a sequencing experiment ultimately depends on the amount and integrity of the nucleic acid template (RNA or DNA) obtained from a sample. “The better the quality of the nucleic acid isolated...
            03-22-2024, 06:39 AM
          • seqadmin
            Techniques and Challenges in Conservation Genomics
            by seqadmin



            The field of conservation genomics centers on applying genomics technologies in support of conservation efforts and the preservation of biodiversity. This article features interviews with two researchers who showcase their innovative work and highlight the current state and future of conservation genomics.

            Avian Conservation
            Matthew DeSaix, a recent doctoral graduate from Kristen Ruegg’s lab at The University of Colorado, shared that most of his research...
            03-08-2024, 10:41 AM

          ad_right_rmr

          Collapse

          News

          Collapse

          Topics Statistics Last Post
          Started by seqadmin, Yesterday, 06:37 PM
          0 responses
          11 views
          0 likes
          Last Post seqadmin  
          Started by seqadmin, Yesterday, 06:07 PM
          0 responses
          10 views
          0 likes
          Last Post seqadmin  
          Started by seqadmin, 03-22-2024, 10:03 AM
          0 responses
          51 views
          0 likes
          Last Post seqadmin  
          Started by seqadmin, 03-21-2024, 07:32 AM
          0 responses
          68 views
          0 likes
          Last Post seqadmin  
          Working...
          X