Viewing a saved revision (read-only)
c64c00046c354e21a54f5a32c90acee2
Codu exercise
A time-series line chart visualizes the total number of homeless individuals in Ireland from July 2014 to June 2024, with individual data points rendered as white circles. The chart uses d3-scale for the time and linear scales, d3-shape’s `line` function to plot the trend, and d3-array’s `extent` and `timeParse` for domain calculations and date formatting. GSAP powers the hover animations on the circles, adjusting their radius. The Svelte components manage the axes and circles, rendered as SVG on a dark navy background.
AI-generated descriptionCodu exercise from talk on 1st august.
{#each data as d, i} <!-- <circle id={'circle_' + i} class="circle" cx={xScale(d.date)} cy={yScale(d.Total)} r={3} ></circle> -->
<!-- <Circle {xScale} {yScale} data={d} {i} />
--> {/each}
<!-- <path
id="lineplot"
fill="none"
stroke="white"
stroke-width="1.5"
d={linePlot(data)}
/>
--> <!-- <text id="yaxis_text" cursor="pointer" x="100" y="50" on:click={() => randomise()}>{'Randomise'}</text > -->