Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

edlib

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

edlib

  • 0.0.9
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

ruby-edlib

Gem Version test DOI

Edlib - A lightweight and super fast C/C++ library for sequence alignment using edit distance

Installation

gem install edlib

The Gem compiles the edlib source code inside the gem at installation. If you want to use the latest edlib, see Development.

Usage

require "edlib"

a = Edlib::Aligner.new(mode: :hw, task: :path)
a.align("AACG", "TCAACCTG")

# {
#  :edit_distance   => 1,
#  :alphabet_length => 4,
#  :locations       => [[2, 4], [2, 5]],
#  :alignment       => [0, 0, 0, 1],
#  :cigar           => "3=1I"
# }
keyword argumentdescription
kedit distance is not larger than k [-1]
modeglobal (NW) , prefix (SHW) , infix (HW) ["NW"]
taskDISTANCE, LOC, PATH ["DISTANCE"]
additional_equalitiesList of pairs of characters, where each pair defines two characters as equal. [NULL]
a.align("AACG", "TCAACCTG", nice: true)

# {
#   :edit_distance=>1,                                                 
#   :alphabet_length=>4,                                               
#   :locations=>[[2, 4], [2, 5]],                                      
#   :alignment=>[0, 0, 0, 1],                                          
#   :cigar=>"3=1I",                                                    
#   :query_aligned=>"AACG",                                            
#   :match_aligned=>"|||-",                                            
#   :target_aligned=>"AAC-"
# }        

Documentation

https://kojix2.github.io/ruby-edlib/

Development

Pull requests welcome!

git clone https://github.com/kojix2/ruby-edlib # Please fork repo
cd ruby-edlib
bundle install
bundle exec rake compile
bundle exec rake test

Use latest edlib

git clone https://github.com/kojix2/ruby-edlib
cd ruby-edlib
bundle install
bundle exec rake edlib:update # Download latest edlib.h and edlib.cpp
bundle exec rake compile
bundle exec rake test

FAQs

Package last updated on 20 Sep 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc