Giter VIP home page Giter VIP logo

graphology's Introduction

Build Status DOI

Graphology

graphology is a robust & multipurpose Graph object for JavaScript and TypeScript.

It aims at supporting various kinds of graphs with the same unified interface.

A graphology graph can therefore be directed, undirected or mixed, allow self-loops or not, and can be simple or support parallel edges.

Along with this Graph object, one will also find a comprehensive standard library full of graph theory algorithms and common utilities such as graph generators, layouts, traversals etc.

Finally, graphology graphs are able to emit a wide variety of events, which makes them ideal to build interactive renderers for the browser. It is for instance used by sigma.js as its data backend.

Installation

To install graphology using npm, run the following command:

npm install graphology

Legacy bundle

Standalone builds of graphology and its full standard library can be found in the repository's releases if you can only rely on your own script tags to load code.

<!-- To use a Graph object -->
<script src="graphology.min.js"></script>
<!-- This exposes a global variable named "graphology" -->
<script>
  const graph = new graphology.Graph();

  const {UndirectedGraph, DirectedGraph} = graphology;
</script>

<!-- To use the standard library -->
<script src="graphology-library.min.js"></script>
<!-- This exposes a global variable named "graphologyLibrary" -->
<script>
  const density = graphologyLibrary.metrics.graph.density(graph);
</script>

Be warned that the standard library bundle often lags behind and is not always completely up to date.

TypeScript usage

Note that graphology also exports type declaration that are installed along using peer dependencies so it can be used with TypeScript out of the box.

If your version of npm is a bit old, you may need to install graphology-types yourself if the peer dependency resolution is not made for you already:

npm install graphology-types

It can also be useful to pin graphology-types version in your package.json to avoid resolution issues sometimes.

How to cite

graphology is published on Zenodo as DOI

You can cite it thusly:

Guillaume Plique. (2021). Graphology, a robust and multipurpose Graph object for JavaScript. Zenodo. https://doi.org/10.5281/zenodo.5681257

Changelog

A complete changelog can be found here.

graphology's People

Contributors

16arpi avatar ameliepelle avatar apitts avatar avenzi avatar boyeborg avatar darabos avatar dkniffin avatar ebroder avatar eric-wieser avatar gluschenko avatar jacomyal avatar jacomyma avatar jamieparkinson avatar kmalski avatar nikelborm avatar panasenco avatar pokrovskyy avatar scottrblock avatar shahzod-davlatov avatar sim51 avatar tanishiking avatar wthrajat avatar yomguithereal avatar zache avatar zakjan avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.