Unconfigured Ad

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Giorgio C
    Member
    • Oct 2010
    • 89

    #1

    Extract multiple sequences on ncbi by gene symbol

    Hi all,

    I have a lot of gene symbols belonging to the same organism and I need to extract the corresponding sequences on ncbi.

    The gene symbol are all like: NMB0001, NMB0010, NMB0015...

    Is there any automated way (scripts, tools,..) in order to obtain the fasta sequences?

    Thanks in advance,
    Giorgio
  • Richard Finney
    Senior Member
    • Feb 2009
    • 701

    #2
    Download gene_info and gene2accession from NCBI.

    run these :
    "wget -nc ftp://ftp.ncbi.nlm.nih.gov/gene/DATA/gene_info.gz"
    "wget -nc ftp://ftp.ncbi.nlm.nih.gov/gene/DATA/gene2accession.gz"
    Run gunzip to get these two files uncompressed and readable.

    Get your genename(s) converted to entrez gene ids (second column), make sure taxonomy id is 122586 (. in your case).
    Convert the gene names to GIs (gene info identifiers) or accessions.

    Like this ...

    bash-3.00# grep NMB0001 gene_info
    122586 902103 NMB0001 NMB0001 - - - - acetyltransferase protein-coding - - - - 20120121

    bash-3.00# grep "122586.902103" gene2accession
    122586 902103 - - - AAF40480.1 7225226 AE002098.2 66731897 - - ? -
    122586 902103 PROVISIONAL - - NP_273067.1 15675949 NC_003112.2 77358697 6 497 - -

    Cut out the the accession(s) you want, either RNA or Protein. Put them into a flat text file as a list.
    You'll want to program using bash/perl/c/command line utilities, whatever to automate the two basic commands above. Be careful.

    There's supposedly "batch entrez" : http://www.ncbi.nlm.nih.gov/sites/batchentrez

    But I've found it to be unreliable. It drops some accessions. Sad but true. You're welcome to try it.

    The absolute best utility for batch downloading is "idfetch" : http://man.cx/idfetch%281%29 . It's command line, takes parameters, you can give it a file of your accessions or GIs and crank it up. ....downloading ... downloading ... downloading ... wahlah ... your file appears ...just like you asked for. I keep an old copy from an old NCBI C toolkit around and ... apparently it's still available in ncbi-tools-bin package ...

    I run this on Linux/Unix command line ...
    sudo apt-get install ncbi-tools-bin
    and idfetch is there !!! So you can install the ncbi-tools-bin package and get it.
    ___
    sudo apt-get install ncbi-tools-bin

    $ man idfetch | head
    IDFETCH(1) NCBI Tools User's Manual IDFETCH(1)



    NAME
    idfetch - retrieve biological data from the NCBI ID1 server

    SYNOPSIS
    idfetch [-] [-F str] [-G filename] [-Q filename] [-c N] [-d str] [-e N]
    [-f str] [-g N] [-i N] [-l filename] [-n] [-o filename] [-q str] [-s str]
    ....
    Last edited by Richard Finney; 01-24-2013, 08:56 AM.

    Comment

    • Giorgio C
      Member
      • Oct 2010
      • 89

      #3
      Thank you so much for your time and suggestions. Actually I tried 'batch entrez' and as you reported, it's not so good; so you're right about that.

      I really like your last option and I'm gonna try that.

      Thanks again.

      Cheers,
      Giorgio

      Comment

      • dexterslab
        Junior Member
        • Jan 2013
        • 5

        #4
        hi,
        you might also wanna look into the BiomaRt package for R.

        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
        • 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

        ad_right_rmr

        Collapse

        News

        Collapse

        Topics Statistics Last Post
        Started by SEQadmin2, 07-31-2026, 02:55 AM
        0 responses
        18 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 07-24-2026, 12:17 PM
        0 responses
        16 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 07-23-2026, 11:41 AM
        0 responses
        16 views
        0 reactions
        Last Post SEQadmin2  
        Started by SEQadmin2, 07-20-2026, 11:10 AM
        0 responses
        26 views
        0 reactions
        Last Post SEQadmin2  
        Working...