Sample
Buse/32
Human rating uses the original dataset scale.
Scores
| Method | Score | Scale | Dataset rank (0–100) |
|---|---|---|---|
| Posnett | 0.383 | 0–1; higher is more readable | 58.6Δ 39.4 |
| Scalabrino | 0.841 | 0–1; higher is more readable | 72.7Δ 25.3 |
| Dorn | 0.566 | 0–1; higher is more readable | 44.4Δ 53.5 |
| Mi | 0.687 | 0–1; higher is more readable | 77.8Δ 20.2 |
| LLOC | 4 | Logical lines; fewer is more readable | 59.6Δ 38.4 |
| DeepSeek V4 Pro | 18.33 | 0–20; mean of three runs | 100.0Δ 2.0 |
| GPT-6.1 Sol | 17 | 0–20; mean of three runs | 62.1Δ 35.9 |
| BTTF | 0.735 | 0–1; higher is more readable | 96.0Δ 2.0 |
| Human | 4.22 | 1–5; original rating | 98.0 |
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.611 | −6.917 |
| Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones. | 158.457 | −5.229 |
| Source linesThe number of non-empty source lines. | 7 | +2.8 |
Intercept 8.87 + feature contributions = -0.476 (log-odds).
Score = sigmoid(-0.476) = 0.383.
| Score | 0.841 |
|---|
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. | 8 | +0.753 |
| 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. | 68.875 | +0.748 |
| Indentation frequencyHow rapidly indentation changes from line to line. | 1 | −0.703 |
| Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right. | 8.625 | −0.665 |
| Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom. | 6.729 | −0.316 |
| Number layout frequencyHow rapidly the number of numeric values per line changes through the code. | 5 | +0.306 |
| Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *. | 0.09 | +0.07 |
Intercept 0.07 + feature contributions = 0.264 (log-odds).
Score = sigmoid(0.264) = 0.566.
| Score | 0.687 |
|---|
| Score | 4 |
|---|
Run 1
The code is highly readable. Structure is logical: a constructor with a brief, clear Javadoc comment. Nesting is flat with no conditional blocks. Intent is unambiguous—initializing a Date from the current calendar. Length is concise and appropriate. Action granularity is well-managed, with each line performing one logical step (obtaining a Calendar, retrieving fields). Reading flow is natural top-to-bottom. The only minor issues are the missing closing brace in the snippet (likely truncated) and the lack of a comment explaining the +1 offset for the month, which could confuse readers unfamiliar with Calendar's zero-based months.
Run 2
The code is highly readable. It has clear intent with a descriptive constructor and a helpful Javadoc comment. Structure is logical: the Calendar instance is obtained, then fields are assigned. Nesting is flat, length is concise, and each line performs a single clear action. The reading flow is natural. Minor deductions: the `+ 1` for month could be slightly clarified with a comment or constant, and the snippet is incomplete (missing closing braces), though that may be due to truncation.
Run 3
The code is highly readable. It has a clear, single-purpose constructor with a descriptive Javadoc comment. The structure is logical: obtain a calendar instance, then assign year and month fields. There is no nesting. Intent is unambiguous – the constructor initializes a Date with the current date. It is concise, with no unnecessary lines. Each line performs one action. The reading flow is natural: comment, calendar creation, field assignments. Minor deductions: the month adjustment (+1) could benefit from a brief comment explaining the zero-based month convention, and the code snippet is incomplete (no closing brace or day assignment), but the visible portion is excellent.
Run 1
Code Structure: The constructor is logically organized, although the snippet is incomplete and lacks a closing brace. Nesting: Flat, with no nested control flow. Clarity of intent: The comment and Calendar calls clearly convey initialization from the current date, though only year and month are shown. Code length: Concise, with no unnecessary statements. Action granularity: Each line performs one assignment or initialization. Reading flow: Natural progression from obtaining the current calendar to extracting year and month; the month adjustment is straightforward but could benefit from explaining Calendar's zero-based months.
Run 2
Code Structure: The constructor is logically organized, but the snippet is incomplete and lacks a closing brace. Nesting: Flat statements within a single constructor make it easy to follow. Clarity of intent: The documentation and Calendar field names clearly indicate initialization from the current date; adding 1 converts the zero-based month. Code length: Concise, with no unnecessary statements. Action granularity: Each line performs one straightforward initialization or assignment. Reading flow: Natural progression from obtaining the current calendar to extracting year and month. The local name mCalendar resembles a member-field name, and the incomplete snippet leaves full date initialization uncertain.
Run 3
Code Structure: The constructor logically groups calendar creation and field initialization, although the snippet lacks a closing brace. Nesting: Flat statements within a single constructor make it easy to follow. Clarity of intent: The documentation and field assignments clearly indicate initialization from the current date; adding 1 converts Calendar's zero-based month. Code length: Concise, with no unnecessary statements. Action granularity: Each line performs one main action. Reading flow: Natural progression from obtaining the calendar to extracting year and month. The incomplete snippet and slightly misleading local-variable prefix m reduce readability.