Giter Club home page Giter Club logo

gephi-python-module's Introduction

Gephi python module

Gephi image

Index

ToDo list

  • All classes
  • Export to .gexf file
  • import from .gexf file

Usage

To use this module you have to write only the import line:

from Gephi import gephi

Documentation

Classes

Graph

Instance
Graph(version, creator, description, mode, default_edge_type)
Variables Type Nullable Options
Version String 1.1 - 1.2
Creator String What you want
Description String What you want
Mode String static - dynamic
Default edge type String directed - undirected - mutual

Method

Permit to add a node in graph node list.

add_node(node)

Return:

  • 0: Node has not been added
    • Node already exist
  • 1: Node has been added
Variables Nullable Type
Node Node

remove_node(node)

Permit to remove node from graph node list. Return:

  • 0: Node has not been removed
    • Node doesn't exist
  • 1: Node has been removed
Variables Nullable Type
Node Node

node_exist(node)

Check if exist a node in graph node list. Return:

  • false: Node already doesn't exist in graph node list
  • true: Node already exist in graph node list
Variables Nullable Type
Node Node

node_id_exist(node)

Check if a node in graph node list has the same id. Return:

  • false: Node id already doesn't exist in graph node list
  • true: Node id already exist in graph node list
Variables Nullable Type
Node Node - string

add_edge(edge)

Permit to add an edge to graph edge list. Return:

  • 0: Edge has not been added
    • Edge already exist
    • Edge source/target association already exist
    • Doesn't exist an association between edge source and a node id
    • Doesn't exist an association between edge target and a node id
  • 1: Edge has been added
Variables Nullable Type
Edge Edge

remove_edge(edge)

Permit to remove an edge from graph edge list. Return:

  • 0: Edge has not been removed
    • Edge doesn't exist
  • 1: Edge has been removed
Variables Nullable Type
Edge Edge

edge_exist(edge)

Check if an edge in graph edge list exist. Return:

  • false: Edge already doesn't exist in graph edge list
  • true: Edge already exist in graph edge list
Variables Nullable Type
Edge Edge

edge_association_exist(edge)

Check if an edge in graph edge list has the same source/target association. Return:

  • false: Edge id already doesn't exist in graph edge list
  • true: Edge id already exist in graph edge list
Variables Nullable Type
Edge Edge

Node

Instance

Node(id, label, color, position, size, shape)
Variables Type Nullable Options
Id String What you want
Label String What you want
Color Color What you want
Position Position What you want
Size Numeric What you want
Shape Numeric What you want

Method

Return a node info string.

to_string()

Edge

Instance

Edge(id, label, type, source, target, weight)
Variables Type Nullable Options
Id String What you want
Label String What you want
Type String directed - undirected - mutual
Source String An existing node id
Target String An existing node id
Weight Numeric What you want

Method

return an edge info string.

to_string()

Color

Instance

Color(r, g, b)
Variables Type Nullable Options
R Numeric Value from 0 to 255
G Numeric Value from 0 to 255
B Numeric Value from 0 to 255

Method

return a color info string.

to_string()

Position

Instance

Position(x, y, z)
Variables Type Nullable Options
X Numeric What you want
Y Numeric What you want
Z Numeric What you want

Method

return a position info string.

to_string()

Methods

Permit to create a .gexf file from a Graph to be import into Gephi afterwards.

create_gefx_file(graph, filename)
Variables Type Nullable Options
Graph Graph What you want
filename String File name .gexf

gephi-python-module's People

Contributors

n36l3c7 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.