cmd

package
v0.8.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 29, 2018 License: MIT Imports: 34 Imported by: 0

Documentation

Index

Constants

View Source
const VERSION = "0.8.1"

VERSION of seqkit

Variables

View Source
var RootCmd = &cobra.Command{
	Use:   "seqkit",
	Short: "a cross-platform and ultrafast toolkit for FASTA/Q file manipulation",
	Long: fmt.Sprintf(`SeqKit -- a cross-platform and ultrafast toolkit for FASTA/Q file manipulation

Version: %s

Author: Wei Shen <shenwei356@gmail.com>

Documents  : http://bioinf.shenwei.me/seqkit
Source code: https://github.com/shenwei356/seqkit
Please cite: https://doi.org/10.1371/journal.pone.0163962

`, VERSION),
}

RootCmd represents the base command when called without any subcommands

View Source
var Threads = runtime.NumCPU()

Threads for bread.NewBufferedReader()

Functions

func Execute

func Execute()

Execute adds all child commands to the root command sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.

func MD5

func MD5(s []byte) string

MD5 of a slice

Types

type BedFeature

type BedFeature struct {
	Chr    string
	Start  int // 1based
	End    int // end included
	Name   *string
	Strand *string
}

BedFeature is the gff BedFeature struct

func ReadBedFeatures

func ReadBedFeatures(file string) ([]BedFeature, error)

ReadBedFeatures returns gtf BedFeatures of a file

func ReadBedFilteredFeatures

func ReadBedFilteredFeatures(file string, chrs []string) ([]BedFeature, error)

ReadBedFilteredFeatures returns gtf BedFeatures of selected chrs from file

type Config

type Config struct {
	Alphabet               *seq.Alphabet
	ChunkSize              int
	BufferSize             int
	Threads                int
	LineWidth              int
	IDRegexp               string
	IDNCBI                 bool
	OutFile                string
	Quiet                  bool
	AlphabetGuessSeqLength int
	ValidateSeqLength      int
}

Config is the global falgs

type RecordLoopBuffer added in v0.7.0

type RecordLoopBuffer struct {
	Size, Capacity int
	Current        *RecordNode
}

RecordLoopBuffer is a loop buffer for FASTA/Q records

func NewRecordLoopBuffer added in v0.7.0

func NewRecordLoopBuffer(capacity int) (*RecordLoopBuffer, error)

NewRecordLoopBuffer creats new RecordLoopBuffer object with certern capacity

func (*RecordLoopBuffer) Add added in v0.7.0

func (buf *RecordLoopBuffer) Add(value *fastx.Record)

Add add new RecordNode

func (*RecordLoopBuffer) Backward added in v0.7.0

func (buf *RecordLoopBuffer) Backward(n int)

Backward moves the current pointer backward N nodes

func (*RecordLoopBuffer) Next added in v0.7.0

func (buf *RecordLoopBuffer) Next() *RecordNode

Next returns next node

func (*RecordLoopBuffer) Prev added in v0.7.0

func (buf *RecordLoopBuffer) Prev() *RecordNode

Prev returns previous node

type RecordNode added in v0.7.0

type RecordNode struct {
	Value *fastx.Record
	// contains filtered or unexported fields
}

RecordNode is the node for double-linked loop list

func (RecordNode) String added in v0.7.0

func (node RecordNode) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL