Sample
Buse/30
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.138 | 0–1; higher is more readable | 40.4Δ 14.1 |
| Scalabrino | 0.615 | 0–1; higher is more readable | 31.8Δ 5.6 |
| Dorn | 0.518 | 0–1; higher is more readable | 37.4Δ 11.1 |
| Mi | 0.038 | 0–1; higher is more readable | 4.0Δ 22.2 |
| LLOC | 5 | Logical lines; fewer is more readable | 29.8Δ 3.5 |
| DeepSeek V4 Pro | 13.33 | 0–20; mean of three runs | 41.9Δ 15.7 |
| GPT-6.1 Sol | 13.67 | 0–20; mean of three runs | 23.2Δ 3.0 |
| BTTF | 0.543 | 0–1; higher is more readable | 57.6Δ 31.3 |
| Human | 2.79 | 1–5; original rating | 26.3 |
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) |
|---|---|---|
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 239.749 | −7.912 |
| 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.526 | −6.79 |
| Source linesThe number of non-empty source lines. | 10 | +4 |
Intercept 8.87 + feature contributions = -1.831 (log-odds).
Score = sigmoid(-1.831) = 0.138.
| Score | 0.615 |
|---|
Feature contributions
| Feature | Value | Contribution (log-odds) |
|---|---|---|
| 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. | 124 | −1.587 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 124 | +1.196 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 1 | −0.703 |
| Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code. | 11 | +0.647 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 1 | +0.398 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.064 | +0.322 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 9.864 | −0.272 |
Intercept 0.07 + feature contributions = 0.072 (log-odds).
Score = sigmoid(0.072) = 0.518.
| Score | 0.038 |
|---|
| Score | 5 |
|---|
Run 1
The code is well-structured and readable. It has a clear purpose: setting a map transform and updating map controls. The method is short with minimal nesting and good action granularity (one action per line). The Javadoc provides helpful context about the parameter's usage. However, the reading flow is slightly interrupted by the long chained method call for retrieving the action, and there's a potential null pointer risk with the cast, which slightly reduces clarity. The logic is straightforward with no unnecessary complexity.
Run 2
The code is moderately readable but has several issues. The method is short and the intent is clear from the Javadoc, but the implementation lacks proper structure. The line creating 'mca' is overly long and chains multiple calls, reducing readability. The null check and update call are only partially shown, making it difficult to assess the complete logic. The action granularity is acceptable as each major operation is on its own line, but the long chained expression could be broken into multiple lines. The nesting is minimal which is good, but the code lacks error handling. Overall, it's understandable but could be improved with better line breaks and reduced chaining.
Run 3
The code is reasonably structured with a clear method name and Javadoc, but readability is undermined by several issues. The most significant problem is the deeply chained, one-line call to retrieve the MapControlsAction — it combines multiple actions in a single statement, making it difficult to parse. Additionally, the method’s intent is split: it sets a field and then performs an unrelated update through a long dependency chain. The use of a raw cast and repeated calls like mca.getMapControls() suggests an opportunity to introduce a local variable. The Javadoc is helpful, but the parameter name ‘mt’ is less descriptive than the documentation implies. Overall, while the logic is straightforward, the dense expression, lack of intermediate variables, and mixing of responsibilities reduce clarity, resulting in a score around 10.
Run 1
Code Structure: The visible statements are logically organized, but missing closing braces leave the method incomplete. Nesting: Only one conditional level, making the logic easy to follow. Clarity of intent: The documentation and method name clearly describe setting the map transform, though abbreviated variables mt and mca reduce clarity. Code length: Concise, but the long action lookup and cast would benefit from wrapping. Action granularity: Each statement performs one main action, although the lookup combines chained calls and a cast. Reading flow: Assignment, action retrieval, and conditional update follow a natural sequence; repeated getMapControls() calls and the abrupt ending slightly disrupt readability.
Run 2
Code Structure: The visible operations are logically organized, but missing closing braces leave the snippet incomplete. Nesting: A single conditional keeps nesting shallow. Clarity of intent: The method name and documentation clearly describe setting the selected map transform; abbreviated names mt and mca slightly reduce clarity. Code length: The snippet is concise, though the action lookup line is long. Action granularity: Each statement performs one main action, but the chained lookup and cast increase complexity within one line. Reading flow: Assignment, action lookup, null check, and update follow a natural sequence; repeated getMapControls() calls and the abrupt ending slightly hinder readability.
Run 3
Code Structure: The visible statements are logically organized, but missing closing braces leave the method incomplete. Nesting: A single conditional keeps nesting shallow. Clarity of intent: The documentation and method name clearly explain the purpose, although abbreviated variables mt and mca reduce clarity. Code length: The snippet is concise, but the long action-retrieval expression could be formatted across lines. Action granularity: Each statement performs one primary action. Reading flow: Assignment, control retrieval, null checking, and updating follow a natural sequence; repeated getMapControls() calls and the abrupt ending slightly disrupt readability.