Bash script to convert Multi-line Fasta to Single-line Fasta !
#!/bin/bash input_filename="multi_line.fasta" output_filename="single_line.fasta" awk '/^>/ {printf("\n%s\n", $0);next; } { printf("%s", $0);} END {printf("\n");}'...137 days ago
Perl and BioPerl script to extract protein sequences using GFF file !
#!/usr/bin/perl use strict; use warnings; use Bio::DB::Fasta; use Bio::SeqIO; # Paths to your GFF file and genome FASTA file my $gff_file = 'path/to/your/file.gff...136 days ago
Python script to parse GFF file
def parse_gff(gff_file): features = [] with open(gff_file, 'r') as f: for line in f: if not line.startswith('#'): # Ignore comment lines...81 days ago