@i-vresse/pdbtbx-ts

JS wrapper around pdbtbx rust crate

https://github.com/i-vresse/pdbtbx-ts

Science Score: 67.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 3 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (9.6%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

JS wrapper around pdbtbx rust crate

Basic Info
  • Host: GitHub
  • Owner: i-VRESSE
  • License: apache-2.0
  • Language: Rust
  • Default Branch: main
  • Size: 106 KB
Statistics
  • Stars: 1
  • Watchers: 5
  • Forks: 1
  • Open Issues: 2
  • Releases: 3
Created almost 4 years ago · Last pushed over 1 year ago
Metadata Files
Readme Changelog Contributing License Code of conduct Citation

README.md

NPM Package for pdbtbx

Wrapper around pdbtbx rust library for reading (crystallographic) Protein Data Bank (PDB) and mmCIF files in JavaScript.

npmjs.com Build DOI fair-software.eu

This NPM package only includes a subset of what the rust library can do. For now it is mainly focused on getting chain names and residue sequence numbers from PDB files.

This package uses wasm-pack and tsup to compile the pdbtbx rust library and its bindings to a NPM package using WebAssembly.

🚴 Usage

Add to your app with

shell npm install @i-vresse/pdbtbx-ts

In NodeJS use

js const pdbtbx = await import('@i-vresse/pdbtbx-ts') await pdbtbx.init() const { readFile } = await import('fs/promises') // A PDB file downloaded from https://github.com/haddocking/haddock3/tree/main/examples/docking-protein-protein/data const content = await readFile('./e2aP_1F3G.pdb', encoding='ascii') const info = pdbtbx.open_pdb(content) { identifier: undefined, chains: [ 'A' ], residue_sequence_numbers: [ 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, ... ], residues_per_chain: Map(1) { 'A' => [ { number: 19, insertion_code: '-' }, { number: 20, insertion_code: '-' }, ... ] }, warnings: [] }

In an application using Vite, vitest and TypeScript use

```js import { init, open_pdb } from 'pdbtbx-ts'

async function parse(content: string) { await init() const info = open_pdb(content) return info } ```

Development

Below are instructions how to develop this repository.

Requirements:

  • Rust
  • wasm-pack
  • NodeJS version 18 or greater

🛠️ Build

To build a NPM package in dist/ directory use

shell npm install npm run build

🔬 Test

Tests can be found in tests/ directory.

Run JS tests that consume wasm.

shell npm run test

🎁 Publish to npmjs.com

shell npm publish --access public .

Owner

  • Name: Interactive Virtual Research Environment for Scientific Software Execution
  • Login: i-VRESSE
  • Kind: organization

Project with Netherlands eScience Center and Bonvin Lab

Citation (CITATION.cff)

# This CITATION.cff file was generated with cffinit.
# Visit https://bit.ly/cffinit to generate yours today!

cff-version: 1.2.0
title: pdbtbx-ts
message: >-
  If you use this software, please cite it using the
  metadata from this file.
type: software
authors:
  - given-names: Stefan
    family-names: Verhoeven
    affiliation: Netherlands eScience Center
    orcid: 'https://orcid.org/0000-0002-5821-2060'
repository-code: 'https://github.com/i-VRESSE/pdbtbx-ts'
abstract: >-
  Wrapper around [pdbtbx rust
  library](https://crates.io/crates/pdbtbx) for
  reading (crystallographic) Protein Data Bank (PDB)
  and mmCIF files in JavaScript.
license: Apache-2.0
identifiers:
  - type: doi
    value: 10.5281/zenodo.6532349
    description: Latest version

GitHub Events

Total
Last Year

Committers

Last synced: almost 3 years ago

All Time
  • Total Commits: 32
  • Total Committers: 3
  • Avg Commits per committer: 10.667
  • Development Distribution Score (DDS): 0.125
Top Committers
Name Email Commits
Stefan Verhoeven s****n@g****m 28
Stefan Verhoeven s****n@e****l 3
Douwe Schulte d****e@u****l 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 7 months ago

All Time
  • Total issues: 1
  • Total pull requests: 4
  • Average time to close issues: N/A
  • Average time to close pull requests: 2 days
  • Total issue authors: 1
  • Total pull request authors: 3
  • Average comments per issue: 2.0
  • Average comments per pull request: 0.0
  • Merged pull requests: 3
  • Bot issues: 0
  • Bot pull requests: 1
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • douweschulte (1)
Pull Request Authors
  • sverhoeven (2)
  • dependabot[bot] (2)
  • douweschulte (1)
Top Labels
Issue Labels
discussion (1)
Pull Request Labels
dependencies (2) enhancement (1)

Packages

  • Total packages: 1
  • Total downloads:
    • npm 51 last-month
  • Total dependent packages: 2
  • Total dependent repositories: 2
  • Total versions: 8
  • Total maintainers: 4
npmjs.org: @i-vresse/pdbtbx-ts

Wrapper around [pdbtbx rust library](https://crates.io/crates/pdbtbx) for reading (crystallographic) Protein Data Bank (PDB) and mmCIF files in JavaScript.

  • Versions: 8
  • Dependent Packages: 2
  • Dependent Repositories: 2
  • Downloads: 51 Last month
Rankings
Dependent repos count: 7.6%
Dependent packages count: 8.8%
Forks count: 11.6%
Average: 13.4%
Downloads: 17.9%
Stargazers count: 20.9%
Last synced: 6 months ago

Dependencies

Cargo.toml cargo
  • console_error_panic_hook 0.1.7
  • pdbtbx 0.9.1
  • serde 1.0
  • serde-wasm-bindgen 0.4.3
  • wasm-bindgen 0.2.81
  • wee_alloc 0.4.5
package-lock.json npm
  • 110 dependencies
package.json npm
  • @types/node ^18.0.0 development
  • tsup ^6.1.2 development
  • typescript ^4.7.3 development
.github/workflows/build.yml actions
  • actions/checkout v3 composite
  • actions/setup-node v3 composite