Skip to content

Commit

Permalink
docs(intro)
Browse files Browse the repository at this point in the history
  • Loading branch information
lmeyerov committed Oct 4, 2024
1 parent 3493427 commit 93bc2ae
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 13 deletions.
28 changes: 16 additions & 12 deletions docs/source/visualization/about.rst → docs/source/about.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Installation
Install PyGraphistry
~~~~~~~~~~~~~~~~~~~~

::
.. code-block:: bash
pip install graphistry
Expand Down Expand Up @@ -124,24 +124,27 @@ PyGraphistry supports various visual encodings to represent different attributes


Example: Adding Color Encodings
~~~~~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Let's add color encodings based on the vulnerability exploited.

.. code-block:: python
# Plot with color encoding
g2 = g.encode_edge_color('vulnName', categorical_mapping={
'MS08067 (NetAPI)': 'red',
'OtherVuln': 'blue',
}, default_mapping='gray')
g2 = g1.encode_edge_color(
'vulnName',
categorical_mapping={
'MS08067 (NetAPI)': 'red',
'OtherVuln': 'blue',
},
default_mapping='gray')
g2.plot()
Now, edges are colored based on the type of vulnerability, helping you distinguish different attack types.

Adjusting Sizes, Labels, Icons, Badges, and More
----------------------------------------
------------------------------------------------

You can adjust further node and edge settings using data. Sample calls include:

Expand All @@ -156,7 +159,7 @@ Additional settings, such as background colors and logo watermarks, can also be


Adding an Interactive Timebar
----------------
-----------------------------

If your data includes temporal information, you can add a timebar to visualize changes over time.

Expand All @@ -169,7 +172,7 @@ If your data includes temporal information, you can add a timebar to visualize c
# Plot with time encoding: Graphistry automatically detects Arrow/Parquet native types
g.plot()
The timebar allows you to interactively explore the graph as it evolves over time.
The timebar appears as soon as the UI detects datetime values, and enables you to interactively explore the graph as it evolves over time.


Applying Force-Directed Layout
Expand All @@ -186,19 +189,20 @@ By default, PyGraphistry uses a force-directed layout. You can adjust its parame
More Layout Algorithms
----------------------

PyGraphistry offers many layout algorithms and settings to help you display your graph meaningfully.
PyGraphistry offers additional layout algorithms of its own, and streamlines using layouts from other libraries, so you can display your graph quickly and meaningfully.

For example, GraphViz layouts can be used for laying out small trees and directed acyclic graphs (DAGs).
For example, GraphViz layouts is known for its high quality for laying out small trees and directed acyclic graphs (DAGs):

.. code-block:: python
# pygraphistry handles format conversions behind-the-scenes
g2 = g1.layout_graphviz('dot')
g2.plot()
Using UMAP for Dimensionality Reduction
---------------------------------------

For large graphs, you can use UMAP for dimensionality reduction to layout the graph meaningfully. UMAP will identify nodes that are similar across their different attributes and connect them into a similarity graph.
For large datasets, you can use UMAP for dimensionality reduction to layout the graph meaningfully. UMAP will identify nodes that are similar across their different attributes and connect them into a similarity graph.

.. code-block:: python
Expand Down
7 changes: 7 additions & 0 deletions docs/source/graphistry.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
10 Minutes to PyGraphistry
==========================
.. toctree::
:maxdepth: 2

about

Login and Sharing
=================
.. toctree::
Expand Down
1 change: 0 additions & 1 deletion docs/source/visualization/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ PyGraphistry Visualization
.. toctree::
:maxdepth: 2

about
plotter

0 comments on commit 93bc2ae

Please sign in to comment.