Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • Balat
    Member
    • May 2010
    • 36

    Problem running vcfutils.pl

    Hi,
    I have done a re-sequencing experiment to identify snps from candidate genes. I want to get a consensus sequence using BAM files generated by mapping reads with BWA. Ultimately I want to use the consensus fasta file in bedtools to get flanking sequences of SNPs. I have followed the commands suggested in the samtools help pages. These are the commands that I used for getting consensus fastq file.

    samtools mpileup -uf ref.fa aln.bam | bcftools view -cg - | vcfutils.pl vcf2fq > cns.fq

    I got the following message from vcfutils.pl and the output file contained mainly 'n's.

    Use of uninitialized value $q in numeric lt (<) at /usr/bin/vcfutils.pl line 508, <> line 51404.
    Use of uninitialized value $q in addition (+) at /usr/bin/vcfutils.pl line 518, <> line 51404.


    Could any one please help me with this.
  • Balat
    Member
    • May 2010
    • 36

    #2
    Can any one help with this?

    Comment

    • swbarnes2
      Senior Member
      • May 2008
      • 910

      #3
      I think you are going to have to make at least part of the mpileup file, and examine it to see if you can eyeball the problem.

      Just looking at the perl script itself:

      my ($b, $q);
      $q = $1 if ($t[7] =~ /FQ=(-?[\d\.]+)/);
      if ($q < 0) { ...
      So there's a line where the FQ regex is failing. That's what's causing the problem.

      Comment

      • Balat
        Member
        • May 2010
        • 36

        #4
        Hi swbarnes2,
        Thank you. I can't see much of a problem in mpileup. I have attached a short mpileup file generated from a high coverage region. Could you see any problem?
        Attached Files

        Comment

        • Balat
          Member
          • May 2010
          • 36

          #5
          I have tested with the older version of samtools and it seems to generate the fastq file from pileup file.

          This is the pipe I used as suggested in the earlier version of help pages.

          samtools pileup -cf ref.fa aln.bam | samtools.pl pileup2fq -D100 > cns.fastq

          I am not sure why the mpileup is failing to get the fastq file.

          Comment

          • aniele_leao
            Junior Member
            • Nov 2014
            • 4

            #6
            Originally posted by Balat View Post
            I have tested with the older version of samtools and it seems to generate the fastq file from pileup file.

            This is the pipe I used as suggested in the earlier version of help pages.

            samtools pileup -cf ref.fa aln.bam | samtools.pl pileup2fq -D100 > cns.fastq

            I am not sure why the mpileup is failing to get the fastq file.
            Hello,
            I have the same problem here, but in line 544, <> line 73.
            I tried samtools pileup -cf ref.fa aln.bam | samtools.pl pileup2fq -D100 > cns.fastq
            But didn't work either. Do You have any suggestions?

            Thank you so much!

            Comment

            • GenoMax
              Senior Member
              • Feb 2008
              • 7142

              #7
              Originally posted by aniele_leao View Post
              Hello,
              I have the same problem here, but in line 544, <> line 73.
              I tried samtools pileup -cf ref.fa aln.bam | samtools.pl pileup2fq -D100 > cns.fastq
              But didn't work either. Do You have any suggestions?

              Thank you so much!
              What version of samtools are you using? For samtools (0.1.19) try: http://samtools.sourceforge.net/mpileup.shtml. If you are using Samtools/Bcftools v.1.1 then the syntax is slightly different.

              Comment

              • aniele_leao
                Junior Member
                • Nov 2014
                • 4

                #8
                I'm using version 0.1.19 and tried the command samtools mpileup -uf ref.fa aln.bam | bcftools view -cg - | vcfutils.pl vcf2fq > cns.fq
                Like in the website, but with no success.

                Comment

                • GenoMax
                  Senior Member
                  • Feb 2008
                  • 7142

                  #9
                  Just to make sure .. you are replacing dummy filenames (ref.fa/aln.bam) with real data when you are running this command?

                  If you have done that what "error" do you see?

                  Comment

                  • aniele_leao
                    Junior Member
                    • Nov 2014
                    • 4

                    #10
                    Originally posted by GenoMax View Post
                    Just to make sure .. you are replacing dummy filenames (ref.fa/aln.bam) with real data when you are running this command?

                    If you have done that what "error" do you see?
                    Yes
                    This is what appear when I give the command
                    [mpileup] 1 samples in 1 input files
                    <mpileup> Set max per-file depth to 8000
                    [afs] 0:0.000 1:0.000 2:0.000
                    Use of uninitialized value in length at /usr/local/bin/vcfutils.pl line 544, <> line 73.
                    Use of uninitialized value in length at /usr/local/bin/vcfutils.pl line 544, <> line 73.

                    Comment

                    • GenoMax
                      Senior Member
                      • Feb 2008
                      • 7142

                      #11
                      What aligner did you use to generate the bam files?

                      Comment

                      • aniele_leao
                        Junior Member
                        • Nov 2014
                        • 4

                        #12
                        Bowtie 1.1.1

                        Comment

                        Latest Articles

                        Collapse

                        • mylaser
                          Reply to Advanced Sequencing Platforms Tackle Neuroscience’s Toughest Genomics Problems
                          by mylaser
                          Kheloyar – Everything You Need to Know About Kheloyaar Login and Kheoyar Id
                          If you are looking for an online gaming platform that offers a user-friendly experience, Kheloyar has become a name that many users search for. Whether you're interested in creating a new account, accessing your dashboard through Kheloyaar Login, or learning how to obtain a Kheoyar Id, understanding the platform's features and account process is essential.
                          This guide explains everything you need to know about...
                          Today, 01:13 AM
                        • SEQadmin2
                          Advanced Sequencing Platforms Tackle Neuroscience’s Toughest Genomics Problems
                          by SEQadmin2



                          Genomics studies in neuroscience face a special challenge due to the brain’s complexity and scarcity of samples. Mapping changes in cell type and state using conventional next-generation sequencing methods remains challenging. Advances in technologies like single-cell sequencing, spatial transcriptomics, and long-read sequencing have opened the door to deeper studies of the brain and diseases like Alzheimer’s, amyotrophic lateral sclerosis (ALS), and schizophrenia.
                          ...
                          07-09-2026, 11:10 AM
                        • SEQadmin2
                          Cancer Drug Resistance: The Lingering Barrier to Rising Survival
                          by SEQadmin2



                          Cancer survival rates have significantly increased in the last few decades in the United States, reaching a combined 70% 5-year survival rate by 2021. Behind this number, there are years of research to find new therapies, drug targets, and early detection methods. But there is one core challenge that keeps slowing down these advances, and it’s about drug resistance.

                          There is no single reason why many patients don’t respond to treatment as expected. Cancer is...
                          07-08-2026, 05:17 AM

                        ad_right_rmr

                        Collapse

                        News

                        Collapse

                        Topics Statistics Last Post
                        Started by SEQadmin2, 07-09-2026, 10:04 AM
                        0 responses
                        12 views
                        0 reactions
                        Last Post SEQadmin2  
                        Started by SEQadmin2, 07-08-2026, 10:08 AM
                        0 responses
                        9 views
                        0 reactions
                        Last Post SEQadmin2  
                        Started by SEQadmin2, 07-07-2026, 11:05 AM
                        0 responses
                        18 views
                        0 reactions
                        Last Post SEQadmin2  
                        Started by SEQadmin2, 07-02-2026, 11:08 AM
                        0 responses
                        31 views
                        0 reactions
                        Last Post SEQadmin2  
                        Working...