Skip to main content

Automated text analysis with networks

Project description

Launch on Binder CI status Documentation Status Install with conda Published in Journal of Open Source Software

textnets represents collections of texts as networks of documents and words. This provides novel possibilities for the visualization and analysis of texts.

Bipartite network graph

Network of U.S. Senators and words used in their official statements following the acquittal vote in the 2020 Senate impeachment trial (source).

This is a Python implementation of Chris Bail’s textnets package for R. It is free software under the terms of the GNU General Public License v3.

The idea underlying textnets is presented in this paper:

Christopher A. Bail, “Combining natural language processing and network analysis to examine how advocacy organizations stimulate conversation on social media,” Proceedings of the National Academy of Sciences of the United States of America 113, no. 42 (2016), 11823–11828, doi:10.1073/pnas.1607151113.

Features

textnets builds on the state-of-the-art library spaCy for natural-language processing and igraph for network analysis. It uses the Leiden algorithm for community detection, which is able to perform community detection on the bipartite (word–group) network.

textnets seamlessly integrates with Python’s excellent scientific stack. That means that you can use textnets in Jupyter notebooks to analyze and visualize your data!

textnets is easily installable using the conda and pip package managers. It requires Python 3.7 or higher.

Read the documentation to learn more about the package’s features.

Citation

Using textnets in a scholarly publication? Please cite this paper:

@article{Boy2020,
  author   = {John D. Boy},
  title    = {textnets},
  subtitle = {A {P}ython Package for Text Analysis with Networks},
  journal  = {Journal of Open Source Software},
  volume   = {5},
  number   = {54},
  pages    = {2594},
  year     = {2020},
  doi      = {10.21105/joss.02594},
}

Learn More

Documentation

https://textnets.readthedocs.io/

Repository

https://github.com/jboynyc/textnets

Issues & Ideas

https://github.com/jboynyc/textnets/issues

Conda-Forge

https://anaconda.org/conda-forge/textnets

PyPI

https://pypi.org/project/textnets/

DOI

10.21105/joss.02594

Archive

10.5281/zenodo.3866676

textnets logo

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

textnets-0.5.3.tar.gz (35.7 kB view details)

Uploaded Source

Built Distribution

textnets-0.5.3-cp38-cp38-manylinux_2_31_x86_64.whl (62.9 kB view details)

Uploaded CPython 3.8manylinux: glibc 2.31+ x86-64

File details

Details for the file textnets-0.5.3.tar.gz.

File metadata

  • Download URL: textnets-0.5.3.tar.gz
  • Upload date:
  • Size: 35.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.10 CPython/3.8.12 Linux/5.8.0-1041-azure

File hashes

Hashes for textnets-0.5.3.tar.gz
Algorithm Hash digest
SHA256 4bbf93a8c8329b1708a3069c1333109b7b6dda4830c34bc399e974936398c531
MD5 cbff2a75480b6130e685872010eaab11
BLAKE2b-256 a84bbadfbfbe84eff25a23d818638b28aefb16cde4bf54d3481326910ba1b29c

See more details on using hashes here.

File details

Details for the file textnets-0.5.3-cp38-cp38-manylinux_2_31_x86_64.whl.

File metadata

  • Download URL: textnets-0.5.3-cp38-cp38-manylinux_2_31_x86_64.whl
  • Upload date:
  • Size: 62.9 kB
  • Tags: CPython 3.8, manylinux: glibc 2.31+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.1.10 CPython/3.8.12 Linux/5.8.0-1041-azure

File hashes

Hashes for textnets-0.5.3-cp38-cp38-manylinux_2_31_x86_64.whl
Algorithm Hash digest
SHA256 077fb2ab5364be6256fda52042e6cb9940588d5d94a447d8394215ae93d29e19
MD5 da0dc37fd5c831a11b8c22e1bada1208
BLAKE2b-256 4b33bffd476694b92b0be141a691c711ebeffa3261a75170519c00c3154f08af

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page