Fork of Working with Time
✓ Published0🌍 Public
This example visualizes temperature readings over time using a scatterplot of circles on an SVG canvas, with time on the x-axis and temperature on the y-axis. The code relies on React hooks (useState, useEffect) to fetch and parse CSV data via d3.csv, converting timestamps with the Date constructor and numeric temperatures. Axes are built with custom React components that leverage d3.scaleTime, d3.scaleLinear, and timeFormat, while d3.extent and max determine scale domains. Points are rendered with a fixed radius, and hover tooltips display formatted date values using d3’s timeFormat.
AI-generated descriptionMIT Licensed