# 堆疊條形圖 ### 預覽圖 --- [![堆疊條形圖.png](https://book.gosu.bar/uploads/images/gallery/2019-12/scaled-1680-/cIIEgCGpWwXCU8S7-%E5%A0%86%E7%96%8A%E6%A2%9D%E5%BD%A2%E5%9C%96.png)](https://book.gosu.bar/uploads/images/gallery/2019-12/cIIEgCGpWwXCU8S7-%E5%A0%86%E7%96%8A%E6%A2%9D%E5%BD%A2%E5%9C%96.png) ### 設定值 --- - #### 資料源 ``` [{ 'State': 'WY', '小於5歲': 25635, '5至13歲': 1890, '14至17歲': 9314 }, { 'State': 'DC', '小於5歲': 30352, '5至13歲': 20439, '14至17歲': 10225 }, { 'State': 'VT', '小於5歲': 38253, '5至13歲': 42538, '14至17歲': 15757 }, { 'State': 'ND', '小於5歲': 51896, '5至13歲': 67358, '14至17歲': 18794 }, { 'State': 'AK', '小於5歲': 72083, '5至13歲': 85640, '14至17歲': 22153 }] ``` - #### 內距 ``` 40, 60, 80, 70 ``` - #### 前置處理函數 Transform ##### 字串展開(fold
列表設定值
類型字串展開
要展開的欄位`小於5歲,5至13歲,14至17歲`
保留欄位State
key年齡段
value人口數量
- #### 圖 Geom ##### 柱狀圖( interval )
列表設定值
欄位State\*人口數量
類型柱狀圖
顏色欄位年齡段
調整欄位堆疊 | stack
- #### 圖示 Legend
列表設定值
啟用開啟
欄位年齡段
位置
排版水平
- #### 極坐標 Coord
列表設定值
類型直角坐標系
轉置true