Skip to main content
100%

Hari-Q3

✓ Published0🌍 Public
Hhlmn4936@gmail.com
Last edited Oct 25, 2024
Created on Oct 25, 2024

This scatter plot visualizes the relationship between horsepower and range for electric vehicles, with each vehicle represented by a steelblue circle positioned along the two axes. The visualization loads data from a remote CSV file and uses D3.js v7 scales, axes, and selection methods to render the plot. Specifically, it employs `scaleLinear`, `extent`, `axisBottom`, and `axisLeft` to map data values to pixel coordinates and display labeled axes for horsepower and range in miles.

AI-generated description

Electric Vehicles Scatter Plot

This project visualizes the relationship between horsepower and range of electric vehicles using a scatter plot. It uses D3.js for rendering the plot and local ES6 modules for organization.

Files:

  • index.html: The main HTML file that sets up the structure of the page.
  • index.js: The JavaScript file that fetches the CSV data and renders the scatter plot.
  • myMessage.js: A module exporting a message to display at the top of the page.
  • style.css: The stylesheet for basic styling of the page.
  • README.md: This file.

How to Run:

  1. Clone or download the repository.
  2. Open index.html in a web browser.
  3. The scatter plot will visualize the relationship between horsepower and range of electric vehicles.
MIT Licensed

Similar vizzes