Embold Rating System

The Embold rating system is a numeric representation of the quality of your source code. The rating is calculated on every level of the software: for a function (or method), a component (or class), a package, and the overall software.

Embold rating ranges from -5 to 5, where -5 indicates poor quality software whereas, 5 indicates an extremely good piece of software.

Rating helps you to quickly compare the quality between your repositories once you have more than one scanned.

In the below example, the Overall rating is the rating score of all the repositories scanned. Rating for individual repositories is also shown on the individual tile of the repository. Eg. Pulsar has a rating of 1.65. It considers all languages of that repository.

2688

Calculate Embold Rating

The overall rating is derived from five sub-ratings: Design (anti-pattern), Metrics, Duplication, Vulnerabilities, and Code Quality (code issues). These sub-ratings are again calculated for all components (functions or classes) and then aggregated for packages (or modules) and the overall repository. Our proprietary quality parameters specify how each sub-ratings is weighted to derive the overall Embold rating.

Metrics

Code Metrics are measures for quantitatively assessing your source code. Embold calculates a large number of metrics, i.e. Lines of Code, Cyclomatic Complexity, or Depth of Inheritance hierarchy. For each metric, there are pre-defined thresholds that are documented in the metrics section of the documentation. The more a certain metric is breached, the bigger the negative impact on the Embold rating.

Duplication

Duplication defines how much of your code is duplicated in one or more places. The higher the duplicated code, the more impact on the core.

Code Issues and Vulnerabilities

Code issues and Vulnerabilities are detected by checking the code against pre-defined rules. Each issue has a severity as critical, high, medium, or low. Critical issues have a higher impact on the rating than low severity issues.

Design Anti Patterns

The design and architecture of your code are evaluated by detecting anti-patterns that identify structural issues within your source code. There are function/method level anti-patterns and component-level design issues. Component-level design issues have a significant impact on the rating. Additionally, each anti-pattern is assigned high, medium, or low severity. High severity design issues have a more significant impact than low severity issues.