microsoft / PowerBI-visuals-FacetKey
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 379 units with 3,502 lines of code in units (64.8% of code).
    • 0 very complex units (0 lines of code)
    • 3 complex units (176 lines of code)
    • 4 medium complex units (156 lines of code)
    • 25 simple units (784 lines of code)
    • 347 very simple units (2,386 lines of code)
0% | 5% | 4% | 22% | 68%
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
ts0% | 11% | 6% | 37% | 45%
js0% | 2% | 3% | 16% | 77%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src0% | 11% | 6% | 37% | 45%
lib/@uncharted.software/stories-facets/src/components/facet0% | 5% | 7% | 13% | 73%
lib/@uncharted.software/stories-facets/src/components0% | 0% | 0% | 22% | 77%
lib/@uncharted.software/stories-facets/src0% | 0% | 0% | 12% | 87%
lib/@uncharted.software/stories-facets/src/templates0% | 0% | 0% | 0% | 100%
lib/@uncharted.software/stories-facets/src/util0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
70 30 1
public update()
in src/FacetsVisual.ts
46 28 1
FacetVertical.prototype._update = function()
in lib/@uncharted.software/stories-facets/src/components/facet/facetVertical.js
60 27 0
FacetHorizontal.prototype.select = function()
in lib/@uncharted.software/stories-facets/src/components/facet/facetHorizontal.js
35 21 1
FacetVertical.prototype._handleTransitionEnd = function()
in lib/@uncharted.software/stories-facets/src/components/facet/facetVertical.js
27 15 1
67 14 2
FacetVertical.prototype._updateSparkline = function()
in lib/@uncharted.software/stories-facets/src/components/facet/facetVertical.js
27 11 0
Group.prototype._performDragging = function()
in lib/@uncharted.software/stories-facets/src/components/group.js
52 10 1
14 10 2
FacetHistogram.prototype.initializeSlices = function()
in lib/@uncharted.software/stories-facets/src/components/facet/facetHistogram.js
49 9 2
Group.prototype.append = function()
in lib/@uncharted.software/stories-facets/src/components/group.js
38 9 1
private syncFacets()
in src/FacetsVisual.ts
35 9 0
private bindFacetsEventHandlers()
in src/FacetsVisual.ts
43 9 0
39 9 1
44 9 2
Group.prototype._handleHeaderTouchMove = function()
in lib/@uncharted.software/stories-facets/src/components/group.js
30 8 1
Facets.prototype.select = function()
in lib/@uncharted.software/stories-facets/src/main.js
32 8 2
private applySelection()
in src/FacetsVisual.ts
25 8 1
IBindable.prototype.off = function()
in lib/@uncharted.software/stories-facets/src/components/IBindable.js
26 7 2
FacetHistogramFilter.prototype._initializeDragging = function()
in lib/@uncharted.software/stories-facets/src/components/facet/facetHistogramFilter.js
42 7 0