1.1.5 • Published 2 years ago

ncats-protvista-viewer v1.1.5

Weekly downloads
499
License
MIT
Repository
github
Last release
2 years ago

ncats-protvista-viewer

This component combines various custom and ProtVista Nightingale components to provide the user with a interactive view of aligned protein sequences. An example is shown on Pharos where the sequence variant data and protein annotations come from ProKinO.

To Install

npm install ncats-protvista-viewer

To Configure

Check out ./test.html for an example of how to set the appropriate attributes to visualize your data.

Data Format

sequence: Nested arrays with calculated values for the degree of conservation (in bits) for each residue, where each residue is an array of objects representing the proportion of each amino acid. Amino acids are represented in single letter abbreviations, and bits are floating point numbers. Totals for all amino acids at each residue maxes out at log_2 20 = 4.322 bits.

sequence = [[{aa: Amino_Acid_Abbreviation, bits: Float}]]

annotations: An array of features to show on the lower protvista-tracks. startResidue and endResidue are the start and end residues. name is the name that will show on hover. type is one of the following values that will determine the style in which the feature is display.

    alpha-helix
    alphaC-beta4 Loop
    beta-strand
    Activation Loop
    Activation Segment
    Catalytic Loop
    Glycine Loop
    Subdomain
    Linker
    KeyAA
    R-Spine
    C-Spine
    R-Spine Shell
    N-Lobe
    C-Lobe
    Gatekeeper
    CMGC Insert
    Motif

Easy Customizations

  • see mapIO in common.js to change the display for each type
  • see typeToTrack in viewer.js to change how different annotation types are sorted into tracks

Using the component in Angular SSR

  • The component only runs in the browser, so load it only in the browser.
  • Set your attributes then too, this is an example for the .js file
if (isPlatformBrowser(this.platformID)) {
    import("ncats-protvista-viewer").then(() => {
        if (this.hasVariants()) {
            this.weblogo.nativeElement.setAttribute('sequence', JSON.stringify(this.target.sequence_variants.residue_info));
        }
        if (this.hasAnnotations()) {
            this.weblogo.nativeElement.setAttribute('annotations', JSON.stringify(this.target.sequence_annotations));
        }
    });
}
  • while the html is like this
<ncats-protvista-viewer class="container" #weblogo></ncats-protvista-viewer>

Contact

  • Author: Keith Kelleher
  • Issues: Please post bugs and comments to the Issues tab
1.1.5

2 years ago

1.1.4

3 years ago

1.1.3

3 years ago

1.1.2

3 years ago

1.0.73

3 years ago

1.0.72

3 years ago

1.0.77

3 years ago

1.0.76

3 years ago

1.0.75

3 years ago

1.0.74

3 years ago

1.1.1

3 years ago

1.0.71

3 years ago

1.0.69

3 years ago

1.0.68

3 years ago

1.0.70

3 years ago

1.0.66

3 years ago

1.0.65

3 years ago

1.0.64

3 years ago

1.0.67

3 years ago

1.0.62

3 years ago

1.0.63

3 years ago

1.0.61

3 years ago

1.0.60

3 years ago

1.0.59

3 years ago

1.0.58

3 years ago

1.0.57

3 years ago

1.0.56

3 years ago

1.0.55

3 years ago

1.0.54

3 years ago

1.0.53

3 years ago

1.0.52

3 years ago

1.0.51

3 years ago

1.0.49

3 years ago

1.0.50

3 years ago

1.0.48

3 years ago

1.0.44

3 years ago

1.0.43

3 years ago

1.0.42

3 years ago

1.0.41

3 years ago

1.0.47

3 years ago

1.0.46

3 years ago

1.0.45

3 years ago

1.0.40

3 years ago

1.0.39

3 years ago

1.0.38

3 years ago

1.0.33

3 years ago

1.0.37

3 years ago

1.0.36

3 years ago

1.0.35

3 years ago

1.0.34

3 years ago

1.0.32

3 years ago

1.0.31

3 years ago

1.0.30

3 years ago

1.0.29

3 years ago

1.0.28

3 years ago

1.0.27

3 years ago

1.0.26

3 years ago

1.0.25

3 years ago

1.0.24

3 years ago

1.0.23

3 years ago

1.0.22

3 years ago

1.0.21

3 years ago

1.0.20

3 years ago

1.0.19

3 years ago

1.0.18

3 years ago

1.0.17

3 years ago

1.0.16

3 years ago

1.0.15

3 years ago

1.0.14

3 years ago

1.0.13

3 years ago

1.0.11

3 years ago

1.0.10

3 years ago

1.0.12

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.2

3 years ago

1.0.3

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago