H3
Unit Size

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 254 units with 4,620 lines of code in units (42.5% of code).
    • 3 very long units (369 lines of code)
    • 16 long units (1,036 lines of code)
    • 46 medium size units (1,539 lines of code)
    • 62 small units (903 lines of code)
    • 127 very small units (773 lines of code)
7% | 22% | 33% | 19% | 16%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
c8% | 22% | 32% | 19% | 16%
h0% | 0% | 66% | 15% | 18%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Logical Component
primary logical decomposition
src/h3lib9% | 20% | 29% | 20% | 19%
src/apps6% | 26% | 37% | 15% | 13%
examples0% | 0% | 35% | 57% | 7%
Legend:
101+
51-100
21-50
11-20
1-10
Alternative Visuals
Longest Units
Top 50 longest units
Unit# linesMcCabe index# params
int H3_EXPORT()
in src/h3lib/lib/h3Index.c
137 27 1
static void generate()
in src/apps/miscapps/generateBaseCellNeighbors.c
122 32 0
int localIjkToH3()
in src/h3lib/lib/localij.c
110 27 3
int h3ToLocalIjk()
in src/h3lib/lib/localij.c
90 23 3
H3Index h3NeighborRotations()
in src/h3lib/lib/algos.c
84 23 3
int _polyfillInternal()
in src/h3lib/lib/algos.c
82 15 3
void _hex2dToCoordIJK()
in src/h3lib/lib/coordijk.c
75 15 2
void _faceIjkToGeoBoundary()
in src/h3lib/lib/faceijk.c
68 14 4
void _faceIjkPentToGeoBoundary()
in src/h3lib/lib/faceijk.c
64 9 3
int main()
in src/apps/miscapps/h3ToGeoHier.c
63 11 2
int main()
in src/apps/miscapps/h3ToGeoBoundaryHier.c
62 11 2
void kmlPtsHeader()
in src/apps/applib/lib/kml.c
59 1 2
int main()
in src/apps/filters/localIjToH3.c
58 10 2
void doCell()
in src/apps/filters/h3ToComponents.c
58 8 2
int _parseArgsList()
in src/apps/applib/lib/args.c
57 17 7
void doCell()
in src/apps/testapps/testH3NeighborRotations.c
56 15 3
int main()
in src/apps/miscapps/h3ToHier.c
54 10 2
H3Index _faceIjkToH3()
in src/h3lib/lib/h3Index.c
54 15 2
int main()
in src/apps/filters/geoToH3.c
52 9 2
int H3_EXPORT()
in src/h3lib/lib/algos.c
50 13 1
void _geoAzDistanceRads()
in src/h3lib/lib/geoCoord.c
50 15 4
int normalizeMultiPolygon()
in src/h3lib/lib/linkedGeo.c
49 8 1
void localIjToH3_traverse_assertions()
in src/apps/testapps/testH3ToLocalIjExhaustive.c
48 10 1
int H3_EXPORT()
in src/h3lib/lib/algos.c
44 13 1
int readBoundary()
in src/apps/applib/lib/utility.c
42 10 2
int H3_EXPORT()
in src/h3lib/lib/h3UniEdge.c
42 13 1
Overage _adjustOverageClassII()
in src/h3lib/lib/faceijk.c
42 12 4
int main()
in src/apps/filters/kRing.c
41 7 2
int main()
in src/apps/testapps/mkRandGeoBoundary.c
40 5 2
int main()
in src/apps/filters/h3ToLocalIj.c
39 8 2
int main()
in src/apps/filters/hexRange.c
39 7 2
int main()
in src/apps/testapps/mkRandGeo.c
39 5 2
int main()
in examples/compact.c
38 5 2
static void fillIndex_assertions()
in src/apps/testapps/testPolyfill.c
38 7 1
int _getEdgeHexagons()
in src/h3lib/lib/algos.c
37 8 6
int main()
in src/apps/filters/h3ToGeo.c
36 11 2
int main()
in src/apps/filters/h3ToGeoBoundary.c
36 11 2
bool GENERIC_LOOP_ALGO()
in src/h3lib/include/polygonAlgos.h
36 8 1
void GENERIC_LOOP_ALGO()
in src/h3lib/include/polygonAlgos.h
36 12 1
void H3_EXPORT()
in src/h3lib/lib/h3Index.c
36 9 1
static void kRing_equals_kRingInternal_assertions()
in src/apps/testapps/testKRing.c
35 6 1
int main()
in src/apps/testapps/testH3NeighborRotations.c
35 11 2
static void auditBaseCellNeighbors()
in src/apps/miscapps/generateBaseCellNeighbors.c
35 13 2
void _faceIjkToVerts()
in src/h3lib/lib/faceijk.c
34 4 3
void _faceIjkPentToVerts()
in src/h3lib/lib/faceijk.c
32 4 3
void printHelp()
in src/apps/applib/lib/args.c
30 9 7
void H3_EXPORT()
in src/h3lib/lib/h3UniEdge.c
29 6 1
void h3SetToVertexGraph()
in src/h3lib/lib/algos.c
28 6 3
int main()
in src/apps/filters/h3ToComponents.c
27 7 2
void h3ToLocalIj_neighbors_assertions()
in src/apps/testapps/testH3ToLocalIjExhaustive.c
27 5 1