Skip to content

Commit e20c435

Browse files
committed
fall 2023 updates (use MoMA data in tutorials)
1 parent e329400 commit e20c435

File tree

14 files changed

+458
-14
lines changed

14 files changed

+458
-14
lines changed

2_1_quantities_and_amounts/README.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ As you're building, don't forget you can always reference the [class code branch
1616

1717
## Assignment:
1818

19-
- [ ] Implement your own version of the bar chart from the demo branch using the files present in the root of this directory (`2_2_quantities_and_amounts/` [index.html](index.html), [style.css](style.css), [main.js](main.js)), just like we did in the tutorials in section 1. You may use the existing dataset, or a new one.
19+
- [ ] Implement your own version of the bar chart from the demo branch using the files present in the root of this directory (`2_2_quantities_and_amounts/` [index.html](index.html), [style.css](style.css), [main.js](main.js)), just like we did in the tutorials in section 1.
20+
- [ ] Use the `MoMA_topTenNationalities.csv` data for this bar chart. It is already referenced in your template.
2021
- [ ] Turn this **vertical bar chart** into a **horizontal bar chart**. This will require adjusting both scales to consider how the data should map back to the svg coordinate plane. (_Tip_: start by getting your bars to show, even if they are not yet positioned/sized correctly -- sometimes it is easier to understand where something should go by seeing where it currently is).
2122

2223
**BONUS:**

2_1_quantities_and_amounts/main.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
// const height = ;
55

66
/* LOAD DATA */
7-
d3.csv('../[PATH_TO_YOUR_DATA]', d3.autoType)
7+
d3.csv('../data/MoMA_topTenNationalities.csv', d3.autoType)
88
.then(data => {
99
console.log("data", data)
1010

2_2_distributions/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ As you're building, don't forget you can always reference the [class code branch
1717

1818
## Assignment:
1919

20-
- [ ] Implement your own scatter plot with a *different dataset* than the one used in our demo.
21-
- [ ] Size the dots by something data related. This requires creating a new scale. Carefully consider the domain and range of this new scale, and do your best to make the domain of the scale *dynamic* (i.e. would the scale still work if the data changed?).
20+
- [ ] Implement your own scatter plot with the MoMA distributions dataset. Your dataset should visualize length and width.
21+
- [ ] Size the dots by the artist lifespan. This requires creating a new scale. Carefully consider the domain and range of this new scale, and do your best to make the domain of the scale *dynamic* (i.e. would the scale still work if the data changed?). Make a design decision to handle the 0 values.
2222
- [ ] Make intentional design decisions -- colors, sizes, axes, etc. should illustrate something interesting about or relevant to your data.
2323

2424
**BONUS:**

2_2_distributions/main.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
// radius = ;
66

77
/* LOAD DATA */
8-
d3.json("[PATH_TO_YOUR_DATA]", d3.autoType)
8+
d3.csv("../data/MoMA_distributions.csv", d3.autoType)
99
.then(data => {
1010
console.log(data)
1111

2_3_time_series/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ As you're building, don't forget you can always reference the [class code branch
1818

1919
## Assignment:
2020

21-
- [ ] Implement your own line chart _with a different dataset_ than the one used in our demo. Your data should only create one line (given then next requirement).
21+
- [ ] Implement your own line chart _with a different dataset_ than the one used in our demo. Your data should only create one line (given the next requirement).
2222
- [ ] Turn this line chart into an [area chart](https://github.com/d3/d3-shape#areas). **Tip**: Think first about how that would be drawn on the screen. What are you creating on the svg? This requires referencing the d3 documention to understand the similarities and differences between the area function generator and the line function generator.
2323
- [ ] Make intentional design decisions -- colors, sizes, axes, etc. should illustrate something interesting about or relevant to your data.
2424

2_4_geographic/README.md

+2-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
The goals for this tutorial are:
44

55
- to reinforce the basic mechanics of how d3 allows you to [select](https://github.com/d3/d3-selection) HTML/SVG elements and map them to data elements.
6-
- to learn the tools to make your own line chart.
76
- to explore GeoJSON data, and how geographical features on our earth translate to projected shapes on an svg.
87
- to understand [projections](https://github.com/d3/d3-geo#projections), in conjunction with [d3.geo-path](https://github.com/d3/d3-geo#geoPath), transforms lattitude and longitude space into pixel space.
98
- to grasp that d3.js svg maps are as simple as lines and circles, and can be manipulated as such, with stroke, fill, etc.
@@ -17,9 +16,9 @@ As you're building, don't forget you can always reference the [class code branch
1716

1817
## Assignment:
1918

20-
- [ ] Implement your own version of the map, using the us state geojson data provided in the [data folder](../data/), or another geojson of your choice (feel free to pull in data of the world or of another country if you like).
19+
- [ ] Implement your own version of the map, using the nationalities data (`MoMA_nationalities`) and the country geojson data (`world.json`) provided in the [data folder](../data/).
2120

22-
- [ ] Using your own lat/long dataset _OR_ the provided dataset for this exercise, [`usHeatExtremes.csv`](../data/usHeatExtremes.csv) (also in the [data folder](../data/)), add points to your map. **HINT:** since we're still in svg, we can just add circles to the map, like we've done before, but you'll need to use your `projection` to translate from (long,lat) values to (x,y) values.
21+
- [ ] Create a world map that highlights countries that have artists represented in the provided dataset. This means you'll have to do some data transformations and mapping to tie the nationality to its country (i.e. "Polish" --> "Poland"). You should do as much data mapping and manipulation as possible _before_ creating a data visualization. You may want to generate a new data file that would best help you tackle this task through another program (like excel or python).
2322

2423
- [ ] Make intentional design decisions -- colors, sizes, labels, etc. should illustrate something interesting about or relevant to your data.
2524

3_1_quantities_and_amounts/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ As you're building, don't forget you can always reference the [class code branch
1313

1414
## Assignment:
1515

16-
- [ ] Implement your own bar chart with a *different dataset* than the one used in our demo. It can be the same dataset you used in the section 2 version of this same tutorial.
16+
- [ ] Implement your own bar chart with the same dataset you used in the section 2 version of this tutorial.
1717
- [ ] Add axes or labels to this chart, as we learned in other tutorials of the previous section.
1818
- [ ] Add a color scale to this chart, as we learned in other tutorials of the previous section.
1919
- [ ] Make intentional design decisions -- colors, sizes, axes, transitions, etc. should illustrate something interesting about or relevant to your data.

3_1_quantities_and_amounts/main.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ let state = {
1313
};
1414

1515
/* LOAD DATA */
16-
d3.csv('[PATH_TO_YOUR_DATA]', d3.autoType).then(raw_data => {
16+
d3.csv('../data/MoMA_topTenNationalities.csv', d3.autoType).then(raw_data => {
1717
console.log("data", raw_data);
1818
// save our data to application state
1919
state.data = raw_data;

3_2_distributions/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ As you're building, don't forget you can always reference the [class code branch
1616

1717
## Assignment:
1818

19-
- [ ] Implement your own scatter plot with a *different dataset* than the one used in our demo. This means your dropdowns will have different values, which correspond to your data.
19+
- [ ] Implement your own scatter plot with the same MoMA distributions dataset from the section 2 tutorial of this data. This means your dropdowns will have different values, which correspond to your data. You could do this by nationality, or gender.
2020

2121
- [ ] Implement a different transition than the one used in the demo (i.e., your dots should not move from left to center to right on transitions). Consider other visible properties that could change as an object is entering, exiting, etc. and what that change suggests about the state of that data point.
2222

3_4_geographic/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ As you're building, don't forget you can always reference the [class code branch
1717

1818
- [ ] Implement your own version of the map, using the us state geojson data provided in the [data folder](../data/), or another geojson of your choice (feel free to pull in data of the world or of another country if you like).
1919

20-
- [ ] Using your own lat/long dataset, add points to your map. This can be the same dataset you chose for the section 2 version of this tutorial, as long as its **not** the dataset leveraged in the section 2 **demo** ([`usHeatExtremes.csv`](../data/usHeatExtremes.csv))
20+
- [ ] Using your own lat/long dataset, add points or fills to your map. This can be the same MoMA data you leveraged for the section 2 version of this tutorial, as well as the data used in the section 2 demo ([`usHeatExtremes.csv`](../data/usHeatExtremes.csv))
2121

22-
- [ ] Add mouseover behavior **to each point**, so its data updates state, and is displayed in our tooltip display.
22+
- [ ] Add mouseover behavior **to each point or polygon**, so its data updates state, and is displayed in our tooltip display.
2323

2424
- [ ] Make intentional design decisions -- colors, sizes, axes, transitions, etc. should illustrate something interesting about or relevant to your data.
2525

0 commit comments

Comments
 (0)