You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+37-18
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,9 @@ Python script to visualize dependencies between cells in Excel spreadsheets.
8
8
9
9
Meant as a tool to visualize and understand the complexity of Excel spreadsheets.
10
10
11
-
Will generate a graph of the dependencies between cells in an Excel spreadsheet. The graph is generated using the `networkx` library (<https://networkx.org/>) and is visualized using `matplotlib`.
11
+
Will generate a graph of the dependencies between cells in an Excel spreadsheet. Data extracted with `openpyxl` (\The graph is generated using the `networkx` library (<https://networkx.org/>) and is visualized using `matplotlib`.
12
+
13
+
This is a simple tool and does not
12
14
13
15
## Definitions
14
16
@@ -18,7 +20,7 @@ A range defined in a formula like `=SUM(B1:B200)` is semantically handled like a
Depending on the size of the spreadsheet you might want to adjust the plot configuration in the code to to make the graph more readable (remove labels, decrease widhts and sizes etc)
37
39
40
+
### Arguments
41
+
42
+
`--verbose` will dump formula cell contents during (more quiet)
43
+
`--no-visualize` will skip the visualization step and only print the summary (faster)
44
+
`--keep-direction` will keep the direction of the graph as it is in the excel file, otherwise it will be simplified to an undirected graph (slower)
45
+
38
46
## Sample output
39
47
48
+
The following is the output of running the script on the provided `Book1.xlsx` file.
49
+
40
50
```bash
41
51
=== Dependency Graph Summary ===
42
-
Number of nodes (cells): 16
43
-
Number of edges (dependencies): 17
44
-
45
-
Nodes with the highest degree:
46
-
Sheet1!B5: 4 dependencies
47
-
Sheet1!B12: 3 dependencies
48
-
Sheet1!B17: 3 dependencies
49
-
Sheet1!I21: 3 dependencies
50
-
Sheet1!G22: 3 dependencies
51
-
Sheet1!B22: 3 dependencies
52
-
Sheet1!B28: 3 dependencies
53
-
Sheet1!G19: 2 dependencies
54
-
Sheet1!B35: 2 dependencies
55
-
Sheet3!A2:A11: 2 dependencies
52
+
Cell/Node count 50
53
+
Dependency count 60
54
+
55
+
=== Nodes with the highest degree ===
56
+
Range!F1 10
57
+
Base!B5 4
58
+
Base!B12 3
59
+
Base!B17 3
60
+
Base!I21 3
61
+
Base!G22 3
62
+
Base!B22 3
63
+
Base!B28 3
64
+
Range!B2 3
65
+
Range!B3 3
66
+
67
+
=== Formula functions by count ===
68
+
SUM 3
69
+
POWER 1
70
+
71
+
Visualizing the graph of dependencies.
72
+
This might take a while...
73
+
74
+
Graph visualization saved to images/.\Book1.xlsx.png
0 commit comments