심화 스터디/시각화

[시각화 스터디] 2021 Week 9 : Can you hide a chart in the map layers?

hyerimir 2022. 3. 15. 00:35

작성자 : 14기 임혜리

 

 

https://www.workout-wednesday.com/2021/03/02/2021w09tab/

 

2021 Week 9: Can You Hide A Chart in the Map Layers? – Workout Wednesday

So, I’m a little late for Mardi Gras – but that didn’t stop me from thinking about King Cake, a New Orleans tradition (with French roots) where a little plastic baby is put inside of a cake that is plastered with green, yellow, and purple frosting wi

www.workout-wednesday.com

 

 

Requirements

  • Same Formatting (colors – Nuriel stone palette, tooltips, etc.)

Map layers에서 모든 레이어들을 제거하고 Style을 Dark로 변환한다.

 주어진 형식대로 Tooltips을 작성하기 위해 필요한 것들을 tooltip shelf로 드래그하고 total population의 format을 million으로 변경하여 M 단위로 나타나도록 변경한다.

 

  • Dashboard Size 1000 X 800
  • # of Sheets: 1

2012년 데이터만 사용하므로 filters에 Year을 옮기고 조건을 지정해준다. 

'Country'라는 Parameter를 생성하고 데이터 타입을 string, allowable values를 List로 한다. 그리고 특정 국가가 아닌 모든 국가가 나타나도록 하는 'None'을 list of values에 추가해준다.

주어진 데이터에는 the percent of population that is urban-dwelling만 존재하므로 Population Rural이라는 calculated field를 생성한다.

Country가 'None'일 때 모든 국가가 나타나도록 하는 calculated field를 생성한다.

Country가 Country/Region과 같을 때 Country로 나타나도록 하는 calculated field를 생성한다.

그리고 바로 위에서 만든 두 가지의 calculated field를 Geographic Role의 Country/Region 형태로 바꿔준다.

 

 

  • Create a filled map of that highlights all of the countries in the dataset with region on the color shelf

All Countries를 더블 클릭하고 Marks를 map형태로 변경한다. 후에 color shelf에 Region을 드래그한다. Same Formatting을 위해 colors를 Nuriel stone palette의 색으로 변경한다. 

 

'Selected Countries' 즉 위에서 Country가 Country/Region과 같을 때 Country로 나타나도록 하는 calculated field를 marks layer에 추가한다. detail로 변경해주고 region별로 색을 다르게 하는 것은 동일하게 할 것이기 때문에 color shelf에 region을 드래그한다. 

 

 

  • When you click on a country in the map, you should only see the selected country with a donut chart that highlights the % of the population that is urban-dwelling

Add Parameter Action change parameter를 통해 Field를 All Countries로 Aggregation을 None으로 변경한다.

parameter를 통해 해당 국가를 선택하면 그 나라의 map만 나타나는 것을 확인할 수 있다.

 

해당 국가를 클릭하면 도넛 차트를 보이게 해야하므로 Selected Countries를 marks layer에 추가하여 pie차트 형식으로 바꿔준다. percentage of rural and urban dwellers를 표현하도록 해야하므로 measure values를 Angle에 추가한다. 

비율 별로 색을 다르게 하기 위해 marks의 color shelf에 measure name을 추가한다. edit color를 사용하여 주어진 형식의 색으로 변경한다.

 

도넛 차트를 만들기 위해 selected countries를 marks layer에 한 번 더 추가하고 color shelf에 selected countries를 드래그한다. label를 추가하고 percent format으로 변경하고 나머지 글씨 크기나 위치도 주어진 형식대로 변경한다.

 

https://public.tableau.com/views/WOW2021_09_Canyouhideachartinthemaplayers/Dashboard1?:language=ko-KR&:display_count=n&:origin=viz_share_link 

 

#WOW2021_09_Can you hide a chart in the map layers?

#WOW2021_09_Can you hide a chart in the map layers?

public.tableau.com