Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ninad
    Member
    • Aug 2011
    • 16

    #1

    How to get hg19.fa?

    I am trying to download a reference genome hg19 from UCSC site.
    I tried to convert hg19.2bit to hg19.fa by twoBitToFa on UCSC tools.
    It said "cannot execute binary file".
    then I tried
    "cat chr1.fa chr2.fa chr3.fa chr4.fa chr5.fa chr6.fa chr7.fa chr8.fa chr9.fa chr10.fa chr11.fa chr12.fa chr13.fa chr14.fa chr15.fa chr16.fa chr17.fa chr18.fa chr19.fa chr20.fa chr21.fa chr22.fa chrX.fa chrY.fa >hg19.fa"
    But when I used this hg19.fa in bwa, it said
    "[bwa_index] fail to open file 'hg19.fa'. Abort!
    Aborted"

    I am still not able to get any reference sequence build.

    Note: I am using Linux and am a beginner.
    Last edited by ninad; 08-18-2011, 09:51 PM.
  • ulz_peter
    Senior Member
    • Feb 2010
    • 219

    #2
    I actually did the exact same command for generating my hg19.fa file and it worked perfectly...
    Are you sure you put the right path of the file as argument for bwa?

    Comment

    • ninad
      Member
      • Aug 2011
      • 16

      #3
      Yes, in fact I am in the same directory. Here is the command,
      "bwa index -a bwtsw -p hg19_bwa hg19.fa "

      Otherwise, have you used the twoBitToFa of UCSC?
      Is there any other source for this file?

      Comment

      • sdvie
        Member
        • Jul 2010
        • 68

        #4
        Just a recommendation, I would not use the "alternative name prefix" option -p . It helps to keep it simple. Also, in the following commands you will typically have to specify the base file (hg19.fa) which then points at all the other aligner-specific indices (in the same directory).

        So this should be sufficient:

        Code:
        bwa index -a bwtsw hg19.fa

        Comment

        • ninad
          Member
          • Aug 2011
          • 16

          #5
          Thanks sdvie for the suggestion.

          Some1 please help asap. Can anyone upload a genome on rapidshare and share the link? I mean sounds ridiculous, but is there any other sophisticated way?

          Or please help about twoBitToFa usage.

          Comment

          • sdvie
            Member
            • Jul 2010
            • 68

            #6
            You can get the utility program TwoBitToFa from here:



            Once you downloaded it, you must change permissions first to allow it to be executed as a program.

            Then you execute it from a terminal:

            without arguments to see the options:

            Code:
            $ /path/to/twoBitToFa
            
            twoBitToFa - Convert all or part of .2bit file to fasta
            usage:
               twoBitToFa input.2bit output.fa
            options:
               -seq=name - restrict this to just one sequence
               -start=X  - start at given position in sequence (zero-based)
               -end=X - end at given position in sequence (non-inclusive)
               -seqList=file - file containing list of the desired sequence names 
                                in the format seqSpec[:start-end], e.g. chr1 or chr1:0-189
                                where coordinates are half-open zero-based, i.e. [start,end)
               -noMask - convert sequence to all upper case
               -bpt=index.bpt - use bpt index instead of built in one
               -bed=input.bed - grab sequences specified by input.bed. Will exclude introns
            
            Sequence and range may also be specified as part of the input
            file name using the syntax:
                  /path/input.2bit:name
               or
                  /path/input.2bit:name
               or
                  /path/input.2bit:name:start-end
            You will only need to execute the simple command:

            Code:
            $ /path/to/twoBitToFa /path/to/hg19.2bit /path/to/hg19.fa
            Good luck.

            Comment

            • ninad
              Member
              • Aug 2011
              • 16

              #7
              Thanks sdvie. But I had already gone through these steps. unfortunately, my linux is i686 and not x86_64.
              Thats why it could not execute the binary I suppose.

              Now, I only have the option of "cat chr*.fa", which did not work.
              I am still stuck to obtain human reference genome hg19!!!

              Comment

              • raonyguimaraes
                Member
                • Jun 2010
                • 38

                #8
                Just download it from here:
                hgdownload.cse.ucsc.edu/goldenPath/hg19/bigZips/chromFa.tar.gz
                them
                tar -zxvf chromFa.tar.gz
                and
                cat chr*.fa > hg19.fa
                Done!
                Last edited by raonyguimaraes; 08-19-2011, 01:58 AM.

                Comment

                • ninad
                  Member
                  • Aug 2011
                  • 16

                  #9
                  Thanks raonyguimaraes,
                  but I already tried that and it is still giving the same problem.
                  ~/chromFa$ cat *.fa >hg19s.fa
                  command:
                  ~/chromFa$ bwa index -a bwtsw hg19s.fa
                  Then this was output:
                  [bwa_index] fail to open file 'hg19s.fa'. Abort!
                  Aborted
                  This is not working right....

                  Comment

                  • raonyguimaraes
                    Member
                    • Jun 2010
                    • 38

                    #10
                    Found a similar question http://seqanswers.com/forums/archive...hp/t-5236.html

                    I have no idea whats going on... Check the version of your bwa

                    Comment

                    • sdvie
                      Member
                      • Jul 2010
                      • 68

                      #11
                      unprobable, but: enough memory available?

                      Comment

                      • raonyguimaraes
                        Member
                        • Jun 2010
                        • 38

                        #12
                        Could be http://seqanswers.com/forums/archive...p/t-10766.html

                        Try to use a small file, index only the chr1.fa

                        Comment

                        • ulz_peter
                          Senior Member
                          • Feb 2010
                          • 219

                          #13
                          I tried to reproduce the error but it worked perfectly with new downloaded chr*.fa files...

                          Is it possible that you have no read permissions on the file?
                          My bwa version is 0.5.9-r16

                          Besides that I can't think of anything else...

                          Comment

                          • ninad
                            Member
                            • Aug 2011
                            • 16

                            #14
                            I went through this even earlier, but I am not getting segmentatioon fault. I also have the latest version of bwa 0.5.7.

                            I am clueless too.

                            Comment

                            • ninad
                              Member
                              • Aug 2011
                              • 16

                              #15
                              @peter
                              I will try using the mentioned specifications by you Peter. my bwa is 0.5.7 (r1310)

                              @raonyguimaraes-
                              I have tried using chr1.fa file and it works perfectly fine.
                              My hg19.fa file is 3 GB big. So considering the bwa indexing limit of 4 GB, it should still work.

                              I have checked permissions for the file, they are perfectly fine.
                              I believe the problem is either in concatenation or size limit. I have used cat in both above mentioned ways and its now resolved.
                              I dont know what can be any other problem.

                              @sdvie -How to check whether enough memory is available or not?

                              Comment

                              Latest Articles

                              Collapse

                              • SEQadmin2
                                Beyond CRISPR/Cas9: Understand, Choose, and Use the Right Genome Editing Tool
                                by SEQadmin2



                                CRISPR/Cas9 sparked the gene editing revolution for both research and therapeutics.1 But this system still showed severe issues that limited its applications. The most prominent were the heavy reliance on PAM sequences, delivery limitations, double-stranded breaks that prompt unintended edits and cell death, and editing inefficiency (both in targeting and in knock-in reliability).

                                Despite this, “CRISPR helped turn genome editing from a specialized technique into
                                ...
                                07-31-2026, 11:01 AM
                              • SEQadmin2
                                Proteomic Platforms: How to Choose the Right Analytical Strategy to Improve Detection and Clinical Applications
                                by SEQadmin2


                                Proteomics platforms are evolving rapidly, with advances in mass spectrometry and affinity-based approaches expanding what researchers can detect and at what scale. As the field moves toward deeper proteome coverage and clinical applications, scientists face an increasingly complex landscape of tools. This article will explore how researchers are navigating these choices to find the right platform for their work.

                                The systematic characterization of the human proteome has
                                ...
                                07-20-2026, 11:48 AM

                              ad_right_rmr

                              Collapse

                              News

                              Collapse

                              Topics Statistics Last Post
                              Started by SEQadmin2, 08-06-2026, 07:41 AM
                              0 responses
                              23 views
                              0 reactions
                              Last Post SEQadmin2  
                              Started by SEQadmin2, 08-03-2026, 10:13 AM
                              0 responses
                              39 views
                              0 reactions
                              Last Post SEQadmin2  
                              Started by SEQadmin2, 07-31-2026, 02:55 AM
                              0 responses
                              44 views
                              0 reactions
                              Last Post SEQadmin2  
                              Started by SEQadmin2, 07-24-2026, 12:17 PM
                              0 responses
                              27 views
                              0 reactions
                              Last Post SEQadmin2  
                              Working...