0.1.9 • Published 9 years ago

fasta v0.1.9

Weekly downloads
1
License
Apache 2
Repository
github
Last release
9 years ago

biojs-io-fasta

Build Status NPM version Dependencies Code Climate NPM downloads

npm install biojs-io-fasta

Use in your browser

Download a compiled version for browser use.

or link to a CDN version

<script src="http://wzrd.in/bundle/biojs-io-fasta@latest"></script>
  • You can find a JSBin to play around with it.
  • Remember that you need CORS to download files from other servers on the web.

Parsing

var Fasta = require('biojs-io-fasta');

1. read a url

Fasta.read(url, function(seqs) { }

function is your async callback.

2. parse string

var seqs = Fasta.parse(str);

Writing

var text = Fasta.export(seqs);

Sequence object

{
  seq: "ABC",
  name: "awesome seq",
  id: "unique id"
}

Develop

npm run build-browser

License

Apache 2