File Complexity Overall
  • There are 35 files with units, with 1,226 lines of code.
    • 0 very complex files (McCabe index sum 251+; 0 lines of code)
    • 0 complex files (McCabe index sum 126-250; 0 lines of code)
    • 1 medium complex files (McCabe index sum 51-125; 302 lines of code)
    • 2 slightly complex files (McCabe index sum 26-50; 178 lines of code)
    • 32 simple files (McCabe index sum 1-25; 746 lines of code)
system0% | 0% | 24% | 14% | 60%
Legend:
251+
126-250
51-125
26-50
1-25


explore: grouped by folders | grouped by complexity
File Complexity per Extension
251+
126-250
51-125
26-50
1-25
js0% | 0% | 24% | 14% | 60%
File Complexity per Logical Decomposition
primary
251+
126-250
51-125
26-50
1-25
core0% | 0% | 61% | 17% | 21%
compatibility0% | 0% | 0% | 44% | 55%
sharing0% | 0% | 0% | 0% | 100%
data0% | 0% | 0% | 0% | 100%
ROOT0% | 0% | 0% | 0% | 100%
timing0% | 0% | 0% | 0% | 100%
string0% | 0% | 0% | 0% | 100%
ajax0% | 0% | 0% | 0% | 100%
dom0% | 0% | 0% | 0% | 100%
array0% | 0% | 0% | 0% | 100%
image0% | 0% | 0% | 0% | 100%
detect0% | 0% | 0% | 0% | 100%
Most Complex Files (Top 35)

The McCabe index of a file grows with its size: per 100 lines tells a large but plain file from a dense one, and most complex unit whether the complexity sits in one unit or is spread over many.

File# lines# unitsMcCabe index
(sum)
per 100
lines
most complex
unit
Promise.js
in core
302 38 64 21 5
Array.js
in compatibility
92 4 31 34 14
state.js
in core
86 7 28 33 10
facebook.js
in sharing
83 8 17 20 4
addWheelListener.js
in compatibility
51 5 15 29 6
44 1 14 32 14
49 8 12 24 2
48 1 12 25 12
events.js
in core
32 5 10 31 3
requestAnimationFrame.js
in compatibility
31 4 9 29 6
Function.js
in compatibility
21 4 8 38 3
throttle.js
in timing
35 2 7 20 6
get.js
in ajax
29 3 7 24 3
twitter.js
in sharing
46 2 6 13 3
34 1 6 18 6
group.js
in data
21 1 6 29 6
getNode.js
in sharing
17 1 5 29 5
find.js
in array
17 2 5 29 4
pad.js
in string
22 1 5 23 5
reindex.js
in data
20 1 5 25 5
email.js
in sharing
28 2 4 14 2
extend.js
in core
15 1 4 27 4
uid.js
in core
13 1 3 23 3
preload.js
in image
15 3 3 20 1
Date.js
in compatibility
8 1 2 25 2
11 2 2 18 1
7 1 2 29 2
cancelAnimationFrame.js
in compatibility
5 1 1 20 1
touch.js
in detect
4 1 1 25 1
8 1 1 13 1
8 1 1 13 1
qsa.js
in dom
6 1 1 17 1
qs.js
in dom
6 1 1 17 1
addCommas.js
in string
6 1 1 17 1
6 1 1 17 1
About This Analysis
  • File complexity is the sum of the McCabe indexes (conditional complexity) of the units (methods, functions...) in a file.
  • Files are classified in five categories based on that sum: 1-25 (simple files), 26-50 (slightly complex files), 51-125 (medium complex files), 126-250 (complex files), 251+ (very complex files). The default bands are five times the unit complexity bands, as a file is a group of units.
  • Only main code files with units are classified. Files without units (languages without unit analysis, or files without functions) have no complexity to measure and are left out rather than counted as simple.
  • A very complex file holds many decisions, which often means it has too many responsibilities: a candidate to split, and a place where changes need more testing.
Learn more...