Unconfigured Ad

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • SeqTroubles
    Member
    • Sep 2016
    • 20

    faidx usage and non specific hits

    Hi All,

    I am using pyfaidx to extract fasta sequence from a multifasta file using a list of locus tags.

    List.txt
    JFCCLHHB_00692
    CKEMPBAI_00693
    FBNBCCDE_01742
    OMPPMJLG_02124
    GKEHKBJF_02074

    file.fasta
    >NOLHFCLD_00001 Magnesium-transporting ATPase, P-type 1
    atgc
    >NOLHFCLD_00003 Serine transporter
    atgc

    my command is
    xargs faidx file.fasta < list.txt > out.fas

    my problem is that faidix is being pretty non-specific in the output. Im getting hits back which I know I shouldnt and I was wondering would the underscore have anything to do with this?
    Last edited by SeqTroubles; 06-21-2017, 05:54 AM.
  • GenoMax
    Senior Member
    • Feb 2008
    • 7142

    #2
    Are you referring to samtools faidx or something else?

    Comment

    • SeqTroubles
      Member
      • Sep 2016
      • 20

      #3
      Originally posted by GenoMax View Post
      Are you referring to samtools faidx or something else?
      pyfaidx. Ill change my description now.

      Comment

      • GenoMax
        Senior Member
        • Feb 2008
        • 7142

        #4
        Tested and appears to work fine. Fasta ID's need to match exactly (unless you want to try reg exp/wild cards).

        Code:
        $ more list.fa
        >JFCCLHHB_00692
        AGCTCGAT
        >CKEMPBAI_00693
        ACGCTG
        >FBNBCCDE_01742
        ACGATCAC
        >OMPPMJLG_02124
        ACGCTCGCTGC
        >GKEHKBJF_02074
        AGCTCGC
        
        $ more list.txt
        JFCCLHHB_00692
        CKEMPBAI_00693
        GKEHKBJF_02074
        
        $ xargs faidx list.fa < list.txt
        >JFCCLHHB_00692
        AGCTCGAT
        >CKEMPBAI_00693
        ACGCTG
        >GKEHKBJF_02074
        AGCTCGC

        Comment

        • SeqTroubles
          Member
          • Sep 2016
          • 20

          #5
          Originally posted by GenoMax View Post
          Tested and appears to work fine. Fasta ID's need to match exactly (unless you want to try reg exp/wild cards).

          Code:
          $ more list.fa
          >JFCCLHHB_00692
          AGCTCGAT
          >CKEMPBAI_00693
          ACGCTG
          >FBNBCCDE_01742
          ACGATCAC
          >OMPPMJLG_02124
          ACGCTCGCTGC
          >GKEHKBJF_02074
          AGCTCGC
          
          $ more list.txt
          JFCCLHHB_00692
          CKEMPBAI_00693
          GKEHKBJF_02074
          
          $ xargs faidx list.fa < list.txt
          >JFCCLHHB_00692
          AGCTCGAT
          >CKEMPBAI_00693
          ACGCTG
          >GKEHKBJF_02074
          AGCTCGC
          Thanks GenoMax.

          I have two lists of tags and one list work perfect but when I execute the second it would appear its just copying all the information from the input fasta. Really weird. Ive already looked over all my data to ensure its valid so I cannot see where the issue is at present.

          In actuality Im running a loop to execute this search looks like
          for f in *.fna; do
          f=$(basename $f .fna); xargs faidx $f.fna < tags.txt > $PWD/out/$f.fas; done
          Last edited by SeqTroubles; 06-21-2017, 08:34 AM.

          Comment

          • GenoMax
            Senior Member
            • Feb 2008
            • 7142

            #6
            Examine your ID file (something like cat -vet yourFile) to see if there are any non-printable characters that could be causing potential issues.

            Comment

            Latest Articles

            Collapse

            • SEQadmin2
              Nine Things a Sample Prep Scientist Thinks About Before Sequencing
              by SEQadmin2


              I’m not a sequencing expert. I’m a purification scientist who uses NGS to evaluate workflows my group develops. With this perspective, we think about the sample first and the NGS workflow second. The sequencer is an exceptionally honest reporter, but it can only report on what you give it, so whether you get clean, interpretable data from an NGS workflow is largely determined before you begin.


              Here are nine questions we think about, in roughly the order they matter, before...
              Yesterday, 07:11 AM
            • SEQadmin2
              From Collection to Sequencing: Why Sample Preparation and Preservation Define Sequencing Data
              by SEQadmin2


              Data variability is still an issue in sequencing technologies despite the advances in reproducibility and accuracy of these platforms. But the problem does not originate in the sequencing itself, but in the previous steps, before the sample reaches the sequencer.


              The first step is collection, followed by preservation and sample preparation for analysis. Most scientists overlook those steps, but not being careful might just be skewing the experiment’s results.
              ...
              06-02-2026, 10:05 AM
            • SEQadmin2
              Single-Cell Sequencing at an Inflection Point: Early Impacts of New Platforms and Emerging Trends
              by SEQadmin2


              With the launch of new single-cell sequencing platforms in 2026, the field stands at an exciting inflection point. This article surveys the most impactful advances in the field and discusses how they’re reshaping research in cancer, immunology, and beyond.


              Introduction

              Single-cell sequencing technologies have undergone remarkable advances over the past decade, transitioning from low-throughput experimental approaches to highly scalable platforms capable of...
              05-22-2026, 06:42 AM

            ad_right_rmr

            Collapse

            News

            Collapse

            Topics Statistics Last Post
            Started by SEQadmin2, 06-17-2026, 06:09 AM
            0 responses
            16 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 06-09-2026, 11:58 AM
            0 responses
            37 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 06-05-2026, 10:09 AM
            0 responses
            43 views
            0 reactions
            Last Post SEQadmin2  
            Started by SEQadmin2, 06-04-2026, 08:59 AM
            0 responses
            49 views
            0 reactions
            Last Post SEQadmin2  
            Working...