pymnet


Namepymnet JSON
Version 1.0.0 PyPI version JSON
download
home_pageNone
SummaryMultilayer network analysis library for Python
upload_time2024-07-24 13:23:56
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseGPLv3
keywords complex networks networks network graphs graph theory graph multilayer networks multilayer network
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # pymnet: A Python Library for Multilayer Networks

[![codecov](https://codecov.io/gh/mnets/pymnet/graph/badge.svg?token=LI6QBAF7N0)](https://codecov.io/gh/mnets/pymnet)

`pymnet` is a Python package for creating, analyzing, and visualizing multilayer networks as formalized by [Kivelä et al. (2014)](https://doi.org/10.1093/comnet/cnu016).
It is designed for network scientists with an easy-to-use yet flexible interface, featuring, inter alia, representations of a very general class of multilayer networks, structural metrics of multilayer networks, and random multilayer-network models. 

To learn more about the concepts and design principles underlying `pymnet`, check out [this overview](https://mnets.github.io/pymnet/overview.html).

## Features

* Written in pure Python
* Full support for general [multilayer networks](http://comnet.oxfordjournals.org/content/2/3/203)
* Efficient handling of multiplex networks (with automatically generated lazy evaluation of coupling edges)
* Extensive functionality –– analysis, transformations, reading and writing networks, network models, etc.
* Flexible multilayer-network visualization (using Matplotlib and D3)
* Integration with [NetworkX](https://networkx.org/) for monoplex network analysis

## Working with pymnet

### Installation
We recommend executing the following command in a virtual environment: 
```console
$ python -m pip install pymnet
```

### Usage
To get started with `pymnet`, check out our [tutorials](https://mnets.github.io/pymnet/tutorials) –– and when in doubt, consult the [API reference](https://mnets.github.io/pymnet/reference.html) contained in our [documentation](https://mnets.github.io/pymnet/).

As an introductory example, with the following code, we can create a small multiplex network capturing different types of social relations between individuals and visualize the result:

```python
import pymnet

net_social = pymnet.MultiplexNetwork(couplings="categorical", fullyInterconnected=False)
net_social["Alice", "Bob", "Friends"] = 1
net_social["Alice", "Carol", "Friends"] = 1
net_social["Bob", "Carol", "Friends"] = 1
net_social["Alice", "Bob", "Married"] = 1

fig_social = pymnet.draw(net_social, layout="circular", layerPadding=0.2, defaultLayerLabelLoc=(0.9,0.9))
```

<p align="center" style="margin-top:-6rem;margin-bottom:-3rem">
    <img alt="An image of a small multiplex social network." width="60%" src="https://github.com/mnets/pymnet/raw/master/socialnet.png"> 
</p>


## Contributing

We welcome contributions!
Before you get started, please check out our [contribution guide](CONTRIBUTING.md).

## Asking Questions

* For bugs, feature requests, etc., please use [GitHub issues][github-issues].
* Otherwise, feel free to contact the main developer: [Mikko Kivelä](http://www.mkivela.com/)

[github-issues]: https://github.com/mnets/pymnet/issues

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "pymnet",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "Complex Networks, Networks, network, Graphs, Graph Theory, graph, Multilayer Networks, multilayer network",
    "author": null,
    "author_email": "Mikko Kivel\u00e4 <mikko.kivela@iki.fi>",
    "download_url": null,
    "platform": null,
    "description": "# pymnet: A Python Library for Multilayer Networks\n\n[![codecov](https://codecov.io/gh/mnets/pymnet/graph/badge.svg?token=LI6QBAF7N0)](https://codecov.io/gh/mnets/pymnet)\n\n`pymnet` is a Python package for creating, analyzing, and visualizing multilayer networks as formalized by [Kivel\u00e4 et al. (2014)](https://doi.org/10.1093/comnet/cnu016).\nIt is designed for network scientists with an easy-to-use yet flexible interface, featuring, inter alia, representations of a very general class of multilayer networks, structural metrics of multilayer networks, and random multilayer-network models. \n\nTo learn more about the concepts and design principles underlying `pymnet`, check out [this overview](https://mnets.github.io/pymnet/overview.html).\n\n## Features\n\n* Written in pure Python\n* Full support for general [multilayer networks](http://comnet.oxfordjournals.org/content/2/3/203)\n* Efficient handling of multiplex networks (with automatically generated lazy evaluation of coupling edges)\n* Extensive functionality \u2013\u2013 analysis, transformations, reading and writing networks, network models, etc.\n* Flexible multilayer-network visualization (using Matplotlib and D3)\n* Integration with [NetworkX](https://networkx.org/) for monoplex network analysis\n\n## Working with pymnet\n\n### Installation\nWe recommend executing the following command in a virtual environment: \n```console\n$ python -m pip install pymnet\n```\n\n### Usage\nTo get started with `pymnet`, check out our [tutorials](https://mnets.github.io/pymnet/tutorials) \u2013\u2013 and when in doubt, consult the [API reference](https://mnets.github.io/pymnet/reference.html) contained in our [documentation](https://mnets.github.io/pymnet/).\n\nAs an introductory example, with the following code, we can create a small multiplex network capturing different types of social relations between individuals and visualize the result:\n\n```python\nimport pymnet\n\nnet_social = pymnet.MultiplexNetwork(couplings=\"categorical\", fullyInterconnected=False)\nnet_social[\"Alice\", \"Bob\", \"Friends\"] = 1\nnet_social[\"Alice\", \"Carol\", \"Friends\"] = 1\nnet_social[\"Bob\", \"Carol\", \"Friends\"] = 1\nnet_social[\"Alice\", \"Bob\", \"Married\"] = 1\n\nfig_social = pymnet.draw(net_social, layout=\"circular\", layerPadding=0.2, defaultLayerLabelLoc=(0.9,0.9))\n```\n\n<p align=\"center\" style=\"margin-top:-6rem;margin-bottom:-3rem\">\n    <img alt=\"An image of a small multiplex social network.\" width=\"60%\" src=\"https://github.com/mnets/pymnet/raw/master/socialnet.png\"> \n</p>\n\n\n## Contributing\n\nWe welcome contributions!\nBefore you get started, please check out our [contribution guide](CONTRIBUTING.md).\n\n## Asking Questions\n\n* For bugs, feature requests, etc., please use [GitHub issues][github-issues].\n* Otherwise, feel free to contact the main developer: [Mikko Kivel\u00e4](http://www.mkivela.com/)\n\n[github-issues]: https://github.com/mnets/pymnet/issues\n",
    "bugtrack_url": null,
    "license": "GPLv3",
    "summary": "Multilayer network analysis library for Python",
    "version": "1.0.0",
    "project_urls": {
        "bug-tracker": "https://github.com/mnets/pymnet/issues",
        "documentation": "https://mnets.github.io/pymnet/",
        "homepage": "https://mnets.github.io/pymnet/",
        "repository": "https://github.com/mnets/pymnet"
    },
    "split_keywords": [
        "complex networks",
        " networks",
        " network",
        " graphs",
        " graph theory",
        " graph",
        " multilayer networks",
        " multilayer network"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7374a382d16240a07993f73400945c5ecb1beb3656f65ed6c104ef7a7d72b4b2",
                "md5": "5931a105da61304d3d999cef4c29203c",
                "sha256": "36b4a2dae174a18d6fac7ece96ccb264f848100f3be6ddf512de3429c25ecdc8"
            },
            "downloads": -1,
            "filename": "pymnet-1.0.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5931a105da61304d3d999cef4c29203c",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 2182948,
            "upload_time": "2024-07-24T13:23:56",
            "upload_time_iso_8601": "2024-07-24T13:23:56.930986Z",
            "url": "https://files.pythonhosted.org/packages/73/74/a382d16240a07993f73400945c5ecb1beb3656f65ed6c104ef7a7d72b4b2/pymnet-1.0.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-07-24 13:23:56",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mnets",
    "github_project": "pymnet",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "pymnet"
}
        
Elapsed time: 2.87232s