Sample
Buse/43
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.269 | 0–1; higher is more readable | 50.5Δ 4.0 |
| Scalabrino | 0.541 | 0–1; higher is more readable | 19.7Δ 26.8 |
| Dorn | 0.362 | 0–1; higher is more readable | 20.2Δ 26.3 |
| Mi | 0.579 | 0–1; higher is more readable | 51.5Δ 5.1 |
| LLOC | 4 | Logical lines; fewer is more readable | 59.6Δ 13.1 |
| DeepSeek V4 Pro | 12.67 | 0–20; mean of three runs | 33.8Δ 12.6 |
| GPT-6.1 Sol | 17 | 0–20; mean of three runs | 62.1Δ 15.7 |
| BTTF | 0.424 | 0–1; higher is more readable | 28.3Δ 18.2 |
| Human | 3.29 | 1–5; original rating | 46.5 |
Views
Select the downloaded ZIP or its extracted folder. Files stay in your browser.
Loading feature diagnosis…
Source regions
Feature contributions
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value. | 4.605 | −6.907 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 138.242 | −4.562 |
| Source linesThe number of non-empty source lines. | 4 | +1.6 |
Intercept 8.87 + feature contributions = -0.999 (log-odds).
Score = sigmoid(-0.999) = 0.269.
| Score | 0.541 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 5 | +0.859 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 0 | −0.804 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 1 | −0.703 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 3.882 | −0.356 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.111 | −0.138 |
| Identifier layout (horizontal)How rapidly the visual pattern of identifier characters changes from left to right. It measures spatial frequency, not the meaning of the names. | 84 | +0.107 |
Intercept 0.07 + feature contributions = -0.566 (log-odds).
Score = sigmoid(-0.566) = 0.362.
| Score | 0.579 |
|---|
| Score | 4 |
|---|
Run 1
The code snippet is a constructor with simple assignments, but it suffers from several readability issues. The parameters are named `klass`, `parameters`, and `i`, which are ambiguous and not descriptive. The field names `fParameters` and `fParameterSetNumber` use Hungarian notation, which is outdated and inconsistent with modern Java conventions. The logic is straightforward and flat, but the lack of context (e.g., class purpose, validation) makes intent unclear. Action granularity is acceptable as each line does one assignment, but the code length is minimal yet still hard to evaluate fully due to missing surrounding context. Reading flow is natural but hindered by poor naming. Structure and nesting are neutral, as there are no nested blocks or tangled logic. Overall, the code is functional but not self-documenting, making it less readable for maintainers.
Run 2
The code is concise and well-structured. It clearly initializes three fields from constructor parameters, with one action per line. The flat structure and straightforward assignments make the intent obvious. Minor improvements could include adding a blank line after super() for visual separation, but overall readability is high.
Run 3
The code is a short constructor with clear intent and flat structure. Each line performs one action, and the naming convention (using 'f' prefix) is consistent but outdated. However, the method signature is somewhat cluttered, and the parameter 'i' is ambiguous — a name like 'parameterSetNumber' would improve clarity. The reading flow is straightforward, and the structure is logical, but the lack of complete context (e.g., missing validation or documentation) slightly limits its effectiveness. Overall, it is readable but could benefit from better parameter naming and modern Java conventions.
Run 1
Code Structure: The constructor is logically organized, invoking the superclass before assigning fields, though the snippet lacks a closing brace. Nesting: Flat, with no nested control flow. Clarity of intent: Initializing a parameterized test runner is clear, but the name 'i' is vague and the 'f' field prefixes are less descriptive than conventional names. Code length: Concise, with no unnecessary statements. Action granularity: Each statement performs one action on its own line. Reading flow: Natural initialization order, slightly weakened by inconsistent spacing around assignment operators and the incomplete snippet.
Run 2
Code Structure: The constructor logically groups superclass initialization and field assignments, though the missing closing brace makes the snippet incomplete. Nesting: Flat, with no nested control flow. Clarity of intent: Clearly initializes a parameterized test runner, but the argument name 'i' is less descriptive than 'parameterSetNumber'. Code length: Concise, with no unnecessary statements. Action granularity: Each line performs one action. Reading flow: Initialization proceeds naturally from the superclass to instance fields; inconsistent spacing around assignment operators slightly reduces polish.
Run 3
Code Structure: The constructor is logically organized, calling the superclass before initializing fields. Nesting: It is flat, with no nested control flow. Clarity of intent: Parameter storage and parameter-set numbering are understandable, though 'i' is vague and the 'f' field prefixes add visual noise. Code length: The snippet is concise without unnecessary statements. Action granularity: Each line performs one action. Reading flow: Initialization proceeds naturally, but inconsistent spacing around assignment operators reduces polish. The missing closing brace makes the provided snippet incomplete.