Bash script to simulate a genome !
# Reference https://github.com/chhylp123/hifiasm/issues/33 # Use Drosophila melongaster PacBio assembly cd /...na2.fastq.gz > random_reads_illumina.log 2>&1 # interleave the paired-end reads...930 days ago
907 days ago
807 days ago
Bash script to convert multiline fasta to single line fasta !
#file.fa is multiline fasta awk '/^>/ {printf("\n%s\n",$0);next; } { printf("%s",$0);} END {printf("\n");}' < file.fa779 days ago
Perl script to find inverted repeats !
#!/usr/bin/perl use strict; use warnings; use Bio::SeqIO; use Bio::Tools::Run::RepeatMasker; my $...sult->repeat_class(); my $rm_start = $rm_result->start(); my $rm_end = $rm_result->end();...437 days ago
Raku script to find SSRs in fastq file !
sub find-ssrs(Str $sequence) { my @ssrs; for 2..$sequence.chars -> $min-r...start => $min-repeats, end => $max-repeat,...ssrs -> $ssr { say " Start: $ssr, End: $ssr...124 days ago
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 {prin...108 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.gf...107 days ago
Python script to parse GFF file
def parse_gff(gff_file): features = [] with open(gff_file, 'r') as f:...'start': int(fields[3]), 'end': int(fields[4]),...')) } features.append(featu...51 days ago