openai / chz
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 205 units with 2,454 lines of code in units (64.4% of code).
    • 3 very complex units (541 lines of code)
    • 2 complex units (216 lines of code)
    • 18 medium complex units (653 lines of code)
    • 10 simple units (199 lines of code)
    • 172 very simple units (845 lines of code)
22% | 8% | 26% | 8% | 34%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
py22% | 8% | 26% | 8% | 34%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
chz22% | 8% | 26% | 8% | 34%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
210 119 2
180 85 2
151 75 2
149 41 3
67 28 2
57 24 2
47 23 3
39 21 2
77 19 2
30 18 2
84 18 3
42 16 2
35 16 3
26 14 1
19 14 1
20 13 2
18 13 1
37 12 2
25 12 3
22 11 2
22 11 1
21 11 1
32 11 2
23 10 3
21 10 2
38 8 2
11 8 1
34 7 1
16 7 4
9 6 1
15 6 1
11 6 2
21 6 1
10 5 1
13 5 1
7 5 2
10 5 1
18 5 3
13 5 1
8 5 1
9 5 1
7 4 2
6 4 2
13 4 2
6 4 2
10 4 1
7 4 2
6 4 2
6 4 1
7 4 1