Questions tagged [fasta]

To be used for questions specific tothe sequence file format `.fasta`. Please minimise usage if the question is more generally about sequence formats.

Filter by
Sorted by
Tagged with
2 votes
2 answers
80 views

Elegant Way to Extract Gene Symbols from FASTA Headers

I've downloaded the RefSeq transcript sequences (FASTA format) for the GRC38 patch 14 build of the human genome and would now like to extract the gene symbols (only) in order from the headers. I'm ...
user avatar
3 votes
3 answers
180 views

How to get strain names/ids contained in a multi FASTA file using seqkit?

FASTA files can be very big and unwieldy, especially if lines are at most 80 characters, one can't speed up browsing them by using less with ...
user avatar
1 vote
2 answers
53 views

Checking that two multiline FASTAs are identical (allowing for different order and lower/upper case)

Is there a good CLI tool that can diff two multiline fasta files, ignoring order, and comparing sequences with identical names with each other pairwise. Bonus points if lower/upper case is tolerated (...
user avatar
1 vote
2 answers
26 views

Generate consensus protein sequence from relatively gappy alignment?

I would like to know what would be the best way to generate a full-length consensus sequence? I want to obtain a single representative sequence from a relatively gappy multiple sequence alignment of ...
user avatar
  • 2,234
0 votes
0 answers
10 views

Comparing loci across catalogs

Context: I'm using the Stacks (v2.59) ref_map.pl command to analyze garden and wild samples of a plant species, and have aligned my paired-end RAD reads to a reference genome (using GSNAP). The goal ...
user avatar
2 votes
3 answers
468 views

How can I add a ";" at the end of each fasta header line in a file?

I have a large fasta file with DNA sequences. I need to add a ; at the end of each header line (lines beginning with >) in ...
user avatar
2 votes
3 answers
87 views

How to programatically download SARS-CoV-2 fasta from NCBI/Genbank via API?

I would like to download a number of SARS-CoV-2 fastas from NCBI/Genbank using a web endpoint. I looked on their website but it's confusing. I have the accession numbers, but can't figure out how to ...
user avatar
4 votes
1 answer
76 views

Programmatic way of accessing the FASTA sequence similarity tool (or similar) in Python

I am looking for a tool that performs a sequence similarity algorithm for proteins. More specifically, I am looking for something that would be usable in Python (or anything else usable in the command ...
user avatar
  • 385
2 votes
1 answer
46 views

Displaying BIC and AICs from MSA nucleotide multisequence fasta file

I am initiating a project reproducing MEGA style trees using R to find the best DNA protein models under AIC/BIC. I have read the R AICs and BIC documentation but I'm struggling to implement this. ...
user avatar
0 votes
0 answers
34 views

Combine different FASTQ belonging to different hypervariable 16s regions

I'm really newbie in 16s microbiome analyses, so sorry for this question. I would like to perform a meta-analysis using only Illumina Amplicons sequences from different studies that have different ...
user avatar
  • 101
1 vote
1 answer
123 views

makeblastdb creating multiple files of unexpectedly large sizes

I have a set of 100 amino acid sequences and I want to perform a BLASTP sesrch against the refseq_protein database. Accordingly I had set up the standalone version ...
user avatar
  • 113
0 votes
0 answers
41 views

Extracting and analyzing structure data of multiple proteins from PDB using Python

I am new to programming and I am given the task to extract structural data of soluble proteins from PDB and then shortlist the soluble enzymes from the extracted data set for further classification ...
user avatar
1 vote
1 answer
75 views

How do you replace multiple sequence names with new names using python?

I have into a dictionary some sequences. I would like to replace the sequences name for new names contained into a dataframe. ...
user avatar
4 votes
1 answer
66 views

Counting hexamers in fasta sequence and identify its structure (and interruptions)

I have a lot of fasta files, each one with thousand of reads containing the hexameric motif "CCCTCT". The hexameric motif is highly continuous in most cases but interruptions may occur. I ...
user avatar
  • 41
1 vote
3 answers
91 views

I have two fasta files READ1 and READ 2. How to identify which one is the reverse and the forward?

As you can see in the picture I have two files from the paired end reads. I would assume READ1 would be forward reads and READ2 would be reverse reads, but my lab colleague told me that that might not ...
user avatar
0 votes
2 answers
268 views

Concatenate multiple fasta files into one file for MLST

I have seven fasta files, one per gene, with more than 400 fasta entries per file, like this: Input: Gene1.fasta ...
user avatar
1 vote
1 answer
43 views

How to plot the gap distribution of contigs wrt to reference genome

I have a contigs file that I generated using Minia and then I have used Minimap2 to map these contigs again to the reference genome. Now I want to plot the gap distribution i.e. gap distance of the ...
user avatar
1 vote
1 answer
32 views

Transfer annotations from one genome assembly to another

I've got an annotated draft genome assembly made using short and long read strategies. I've also done optical mapping to stitch some of the contigs together, with the goal being chromsome-length ...
user avatar
  • 11
0 votes
2 answers
224 views

Create BED file from list with gene symbols

Is there a way to generate a BED file of a list of gene symbols for a given genome?
user avatar
-1 votes
1 answer
123 views

How to get a FASTA format file with the DNA sequences of all annotated genes?

I am analysing Pyrococcus Furiosus DNA sequencing data by considering data published here in NCBI. When I click on "Send to">"Gene Features">"FASTA format" I ...
user avatar
1 vote
2 answers
57 views

How to check if a fasta file and a GTF file fit and form a valid pair?

I'd like to know if there is a simple way to check the concordance between a GTF file and a fasta file (that I use as mapping reference) ? It may be a dumb question, but I suspect discrepancies ...
user avatar
  • 111
0 votes
1 answer
52 views

How to know if the DNA sequence has been assembled and why is it important to know how it was assembled?

I have downloaded my FASTA format files, that have the DNA sequences of the coding region of the genes and the DNA sequence of the complete genome, from NCBI. How can I recognize if these sequences ...
user avatar
0 votes
1 answer
357 views

Converting Fastq files to Fasta files on Ubuntu

I am new to bioinformatics and programming. I tried to convert my fastq files to fasta file, but got this. What could be wrong? ...
user avatar
0 votes
2 answers
112 views

Remove from Multi-FASTA by Sequence ID

I want to remove sequence VRE32514 – it doesn’t belong and thus is the reason it lacks additional metadata. However I tried implementing this code from a similar question: ...
user avatar
1 vote
2 answers
128 views

Can the header line contain arbitrary text in FASTA format?

The following is a valid .fasta file content: ...
user avatar
  • 270
0 votes
1 answer
689 views

Converting fastq to fastq.gz on windows

I downloaded some of my data in fastq format instead of fastq.gz. I want to upload my data on a server now. I was wondering if there is a way to convert my fastq files to fastq.gz on windows (I read ...
user avatar
1 vote
2 answers
145 views

How to identify the DNA sequence of a gene in the complete genome sequence FASTA format file?

I need to identify the sequence of a gene in the complete genome sequence . I thought it was simple, instead it is not a straightforward task ! My method was the following: I downloaded the FASTA ...
user avatar
2 votes
3 answers
436 views

How to extract subset of protein structure (PDB format) file based on a subsequence of that protein

I looking at a particular protein structure called 2LY4 accessible from RSCB PDB website. The corresponding fasta sequence for that structure is this: ...
user avatar
  • 155
2 votes
1 answer
39 views

Python package or CLI tool outputting mutations of sequence with respect to reference

I'm new to bioinformatics, and I'm looking for a tool that takes two FASTA files, one containing a reference, let's call it A.fasta, the other another sequence, let'...
user avatar
1 vote
2 answers
192 views

Retain only part of a file name and fasta header in fasta directory

I have a MainDirectory/hundreds_of_subdirectories/thousands_of_fastas structure. For each fasta in the bottom level, I am trying to change the file name as well as ...
user avatar
  • 21
1 vote
0 answers
67 views

How can I extract sequences from FASTA file using OTUs ID?

I have one FASTA file with sequences and headers, and one OTUs table. What I want to do is replace the current headers in the FASTA file with just the OTU IDs from the .txt file. The files look like ...
user avatar
  • 11
1 vote
0 answers
21 views

How can I speed up FASTA ssearch output?

I'm trying to predict targets for miRNA sequences, and so far after reading some papers for other tools that do this, I've found that I should be using FASTA's ...
user avatar
  • 111
0 votes
1 answer
396 views

Using Entrez.efetch() to retrive .fasta file from any NCBI database?

I tried to use these python codes to retrieve a .fasta file from gene database, but the output were the parameters of the report ...
user avatar
1 vote
2 answers
42 views

How to input the opposite strand of DNA?

I am trying to write a program that will count the repeats of a given DNA strand: I am using a Counter library, something like this code shown below ...
user avatar
  • 103
3 votes
2 answers
169 views

Sequence allignment with suffix array?

I'm writing the code from scratch and not using libraries for the actual indexing/search since it's a project for school. Any blackbox advice is fairly useless. I'm planning on aligning some short ...
user avatar
  • 33
5 votes
3 answers
1k views

Removing duplicate FASTA sequences based on headers with Bash

I used the following command to remove duplicate FASTA sequences based on the header sequence: ...
user avatar
  • 51
1 vote
0 answers
34 views

Combine two alleles to genotype locus?

I have a following fasta (produced by stacks populations): ...
user avatar
  • 11
1 vote
1 answer
62 views

Biopython BioSQL error : AttributeError: 'DBSeq' object has no attribute '_data'

Hi I am playing with Biopython and BioSQL, I manage to create an MySQL database using Managing local biological databases with the BioSQL module tutorial: and load 2909 fasta sequences in it through: <...
user avatar
  • 276
0 votes
1 answer
92 views

Converting FASTA Sequences to SNP FASTA Format

I have two FASTA sequences. Each is from a different species' mitochondrial genome. The sequences are pasted below. ...
user avatar
2 votes
2 answers
250 views

Remove Redundant Sequences from FASTA file with Biopython reducing memory footprint

I need help with my Biopython code, I am kind of new to Python and Biopython so please don't be harsh on me. Everything started from here: Remove duplicated sequences in FASTA with Python I answered ...
user avatar
  • 276
0 votes
1 answer
50 views

Extract features from fasta sequences and train the classifier

I am new to the bioinformatics field. I have positive and negative protein sequences for acetylation PTM. Now, I want to train a classifier, say SVM. What will be the next step? How can I convert ...
user avatar
1 vote
1 answer
101 views

Find species from FASTA files

In a school project we got the task of finding the species from two FASTA files. We got some hints of what to look for, like it is a unicellular eukaryote and that we can use blast. We don't know if ...
user avatar
  • 21
1 vote
3 answers
759 views

Filtering Sequences (entries) by headers ID from a Fasta file database

First of all, sorry if this question has been posted previously (I could not found a solution accessing the previous Q&A). I have a fasta file as follow: ...
user avatar
-2 votes
1 answer
47 views

Does anyone know how I can convert DNA code into FASTA for this TTGAAACACTGGATGAATGAAAAGCCCTGCTTTGCAACCCCTCAGC [closed]

TTGAAACACTGGATGAATGAAAAGCCCTGCTTTGCAACCCCTCAGC this is the DNA code Sequence. I have tried converting each into the amino acid and ended up with this LKHWMNEKPCFATPQX but I was told that this isn't ...
user avatar
0 votes
3 answers
50 views

Genome QC + Assembly Pipeline semantics

I’m trying to create a pipeline for genome assembly. How best can I “redirect/pipe” from existing fasta files (or files in general) to other steps of the pipeline? I was thinking of going from the SRA ...
user avatar
1 vote
1 answer
60 views

How to get matching pattern along with ID in a single command in grep?

I have a file containing multiple fast sequneces. For a specific consensus pattern as input, I extracted all the matching patterns from target fasta sequences with ...
user avatar
  • 13
1 vote
1 answer
116 views

How to write multi-sequence alignment data frame as a fasta format fast

I have a data frame where the row names are the species names, and each column can either be an Amino-Acid character or "-". I wish to write it in a fasta format. Simple example of the ...
user avatar
  • 123
2 votes
0 answers
50 views

Why do I obtain different output results with blast vs awk commands

I have an awk command that identifies 30 pb from two multifasta files. When I used two input files: E.g. 100 sequences each, I get the same result with the ...
user avatar
  • 41
-1 votes
1 answer
208 views

Biopython SeqIO check input file

Hi I am trying to learnt python3 and Biopython, I am trying to check imported fasta file before processing so far using: ...
user avatar
  • 276
1 vote
1 answer
79 views

Metagenome simulation from a concatenated FASTA file

I am trying to simulate metagenome sequencing. So I will start with a file with a lot of concatenated genomes. From there, I would like to randomly extract 10,000 sequences of length 200bps. I got ...
user avatar
  • 41