Categorygithub.com/danielschuette/cloningprimer
modulepackage
0.0.3
Repository: https://github.com/danielschuette/cloningprimer.git
Documentation: pkg.go.dev

# README

CloningPrimer

GitHub (pre-)release GoDoc Packagist Build Status codecov

About

Cloning Primer is a software tool that facilitates the design of primer pairs for gene cloning. Given a certain nucleotide sequence and a set of parameters (see Documentation), it returns forward and reverse primers as well as useful statistics like GC content, the probability of the primer pair to form dimers, and much more.

The software is accessible via a web application, but it is recommended to download the command line application (CLI) to enable offline use. Also, an API (written in Go) is available through this GitHub repository. Cloning Primer is under active development, so source code, web interface, API, and CLI might change in the future!

A working version of Cloning Primer is currently available as a pre-release version v0.0.3. Please review the documentation section of this README file for more information about available functionality.

Overview

A pre-release version of the web application is available here.

CLI binaries can be downloaded from ./bin in this repository.

Table of Contents

  1. About

  2. Overview

  3. Documentation

  4. License

Documentation

Application Programming Interface (API)

More documentation regarding the Go API of Cloning Primer is available here.

A minimal, working example:

package main

import (
	"fmt"
	"log"

	cloningprimer "github.com/DanielSchuette/cloningPrimer"
)

func main() {
	// define an input string (must be a valid nucleotide sequence)
	input := "ATGCAAAAACGGGCGATTTATCCGGGTACTTTCGATCCCATTACCAATGGTCATATCGATATCGTGACGCGCGCCACGCAGATGTTCGATCACGTTATTCTGGCGATTGCCGCCAGCCCCAGTAAAAAACCGATGTTTACCCTGGAAGAGCGTGTGGCACTGGCACAGCAGGCAACCGCGCATCTGGGGAACGTGGAAGTGGTCGGGTTTAGTGATTTAATGGCGAACTTCGCCCGTAATCAACACGCTACGGTGCTGATTCGTGGCCTGCGTGCGGTGGCAGATTTTGAATATGAAATGCAGCTGGCGCATATGAATCGCCACTTAATGCCGGAACTGGAAAGTGTGTTTCTGATGCCGTCGAAAGAGTGGTCGTTTATCTCTTCATCGTTGGTGAAAGAGGTGGCGCGCCATCAGGGCGATGTCACCCATTTCCTGCCGGAGAATGTCCATCAGGCGCTGATGGCGAAGTTAGCGTAG"

	// find forward primer with EcoRI restriction site and 5 random nucleotides as an overhang
	forward, err := cloningprimer.FindForward(input, "GAATTC", 1, 18, 4, false)
	if err != nil {
		log.Fatalf("error finding forward primer: %s\n", err)
	}
	if forward == "" {
		log.Fatalf("no forward primer found\n")
	}

	// find reverse primer with BamHI restriction site and 3 random nucleotides as an overhang
	reverse, err := cloningprimer.FindReverse(input, "GGATCC", 1, 20, 3, true)
	if err != nil {
		log.Fatalf("error finding reverse primer: %s\n", err)
	}
	if reverse == "" {
		log.Fatalf("no reverse primer found\n")
	}

	// print results
	fmt.Printf("input: %s\nforward primer: %s\nreverse primer: %s\n", input, forward, reverse)
}

Command Line Interface (CLI)

Documentation is coming soon.

Web Application

Documentation is coming soon.

License

This software is licensed under the MIT license, see LICENSE for more information.

# Packages

No description provided by the author
No description provided by the author

# Functions

AddOverhang appends pseudo-random nucleotides as an overhang to the front (`front' = True) or back (`front' = False) of the input nucleotide sequence `seq' (overhang is of length `len').
CalculateGC takes a `primer' as an input and returns the GC nucleotide content as a floating point number between 0.0 and 1.0.
CalculateTm takes a `primer' (5' -> 3') as an input and returns the melting temperature (or Tm) as a floating point number; it uses the formula: Tm = 2°C * (A + T) + 4°C * (C + G) `complementary' indicates how many nucleotides (from the 3' end of the `primer') should be considered if `complementary' is `0', this argument is ignored and the entire `primer' is used for calculations.
Complement finds the complement of a nucleotide sequence (i.e.
FilterEnzymeMap takes a map with keys of type `string' and values of type `RestrictEnzyme' and returns a slice of strings containing enzyme names that match a certain query string `query'.
FindForward finds a forward primer with a `length' number of complementary nucleotides, binding to the specified starting position (`seqStart'), counting from the 5' end) and up to (`seqStart' + `length' - 1); e.g.
FindReverse finds a reverse primer with a `length' number of complementary nucleotides, binding to the specified start position measured from the 3' end of `seq' up to nucleotide (`seqStart' + `length' -1); `random' indicates the number of random nucleotides to be added to the primer; `restrict' indicates the restriction enzyme recognition site; the boolean `stopCodon' indicates if a stop codon should be added to the primer (only evaluated if the last 3 nucleotides of the sequence underlying the primer do not make up a valid stop codon - in that case, the stop codon adds three nucleotides to the total length of the primer).
HasStartCodon returns true if the first 3 characters of a given input sequence `seq' are 'ATG' if `exact' is false, the entire sequence is checked for the triplet 'ATG'.
HasStopCodon1 (see also ...2, ...3) returns true if the first 3 characters of a given input sequence `seq' are reversed complements of the stop codon TAA if `exact' is false, the entire sequence is checked for the reverse complement of TAA.
HasStopCodon2 tests reverse complement of TAG (see HasStopCodon1).
HasStopCodon3 tests reverse complement of TGA (see HasStopCodon1).
IsNucleotide returns a boolean if input rune is a valid nucleotide letter (i.e.
ParseEnzymesFromFile parses enzyme data (identifiers, recognition sequences, etc.) from a *.re file (see the example in ./assets/enzymes.re) and returns a map with enzyme names as keys and `restricEnzyme' structs as values.
ParseSequenceFromFile parses a plasmid or DNA sequence from a *.seq file (see the example in ./assets/tp53.seq) and returns the sequence as a string.
Reverse finds the reverse of a nucleotide sequence; it requires prior checking of possible sources of errors (for example, it does not check if the input sequence contains invalid nucleotide letters); thus, `Reverse' should be called in the context of a valid `seq' input argument.
ValidateSequence takes a slice of bytes as an input and checks if it contains anything else but valid nucleotide letters ('A', 'G', 'T', 'C'); lower case letters are accepted and capitalized '/n' and white spaces are silently ignored and a valid sequence is returned to the caller.

# Constants

Codon is a sequence of 3 nucleotides.
MaximumPrimerLength gives the maximum length that a primer can be.
MinimumPrimerLength gives the minimum length that a primer must be.

# Structs

RestrictEnzyme is an internally used struct that holds data of a certain restriction enzyme.