You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The plot displays a scatter chart of 12 tech companies comparing Market Cap (x-axis, in Billion USD) vs Annual Revenue (y-axis, in Billion USD). Each blue circular marker represents a company, with connecting arrows pointing to white-background annotation boxes containing company names in bold text. The title "scatter-annotated · plotly · pyplots.ai" appears at the top center. Companies shown include Amazon (highest revenue ~520B), Apple (highest market cap ~2800B), Microsoft, Alphabet, Meta, Tesla, Nvidia, Samsung, TSMC, Oracle, Salesforce, and Netflix. The plot uses a clean white template with subtle grid lines, and annotations are well-positioned with minimal overlap.
Quality Score: 92/100
Criteria Checklist
Visual Quality (37/40 pts)
VQ-01: Text Legibility (10/10) - Title is large and clear, axis labels are well-sized (24pt), tick fonts are readable (18pt), annotations at 18pt are perfectly legible
VQ-02: No Overlap (8/8) - All annotations are manually positioned with custom offsets to avoid overlap; each label is clearly readable without collision
VQ-03: Element Visibility (7/8) - Markers size=20 with opacity=0.7 are well-sized for 12 points; white border provides good contrast. Slightly smaller than optimal for this data density.
VQ-04: Color Accessibility (5/5) - Single blue color (#306998) is colorblind-safe; good contrast against white background
VQ-05: Layout Balance (4/5) - Good use of canvas space; plot fills ~60% of canvas; margins are balanced. Minor: bottom-left area has some label clustering
VQ-06: Axis Labels (2/2) - Descriptive with units: "Market Cap (Billion USD)" and "Annual Revenue (Billion USD)"
VQ-07: Grid & Legend (1/2) - Grid is subtle (alpha 0.1), no legend needed for this plot type. Grid could be slightly more visible.
Spec Compliance (25/25 pts)
SC-01: Plot Type (8/8) - Correct scatter plot with annotations
SC-02: Data Mapping (5/5) - X=market cap (numeric), Y=revenue (numeric), labels=company names (string) - all correctly mapped
SC-03: Required Features (5/5) - All spec features present: text annotations, connecting arrows from labels to points, moderate transparency (0.7), appropriate font size
SC-04: Data Range (3/3) - Axes show all data with appropriate padding (range extends beyond min/max values)
SC-05: Legend Accuracy (2/2) - N/A for this plot type (no legend needed)
SC-06: Title Format (2/2) - Correct format: "scatter-annotated · plotly · pyplots.ai"
Data Quality (18/20 pts)
DQ-01: Feature Coverage (7/8) - Shows variety of annotation positions, different data point distributions. Good spread across quadrants. Minor: could show more extreme outliers.
DQ-02: Realistic Context (7/7) - Real tech companies with plausible market cap and revenue values; neutral business topic
DQ-03: Appropriate Scale (4/5) - Values are realistic for 2024 tech companies. Minor: Nvidia's low revenue relative to market cap is accurate but some values slightly dated.
Code Quality (10/10 pts)
CQ-01: KISS Structure (3/3) - Clean structure: imports → data → figure → trace → annotations → layout → save
CQ-02: Reproducibility (3/3) - np.random.seed(42) is set (though not strictly needed since data is hardcoded)
CQ-03: Clean Imports (2/2) - Only numpy and plotly.graph_objects imported, both used
CQ-04: No Deprecated API (1/1) - Uses current plotly API
CQ-05: Output Correct (1/1) - Saves as plot.png and plot.html
Library Features (2/5 pts)
LF-01: Uses distinctive library features (2/5) - Uses graph_objects annotations with arrows, but doesn't leverage plotly's interactive hover (disabled by using static mode primarily). Hover template is defined but the HTML export is secondary. Could better showcase plotly's interactivity as a core feature.
Strengths
Excellent manual annotation positioning with custom offsets for each company prevents label overlap
Clean annotation styling with white background boxes, blue borders, and connecting arrows
Good use of realistic tech company data that makes the plot immediately comprehensible
Proper title format and descriptive axis labels with units
Both PNG and HTML exports provided
Weaknesses
Does not fully leverage plotly's interactive capabilities as a distinctive feature (hover is secondary to static annotations)
Grid opacity (0.1) is too subtle and could be slightly more visible (0.2-0.3 recommended)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implementation:
scatter-annotated- plotlyImplements the plotly version of
scatter-annotated.File:
plots/scatter-annotated/implementations/plotly.py🤖 impl-generate workflow