---
title: 【Tableau】バタフライチャートの利用方法
description: バタフライチャートは、2つの系列を左右に並べて横棒グラフで示したもので、その代表的な例は「人口ピラミッド」です。 バタフライチャートは「年齢」「性別」ごとの人数を可視化する際によく使われる典型的なチャートです。チャートを作る手順を画像付きでわかりやすく解説します。
image: https://knowledge.insight-lab.co.jp/hubfs/Imported_Blog_Media/26.png
---

![INSIGHT LAB_文字のみ_WHT-1](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/INSIGHT%20LAB_%E6%96%87%E5%AD%97%E3%81%AE%E3%81%BF_WHT-1.png?width=400&height=110&name=INSIGHT%20LAB_%E6%96%87%E5%AD%97%E3%81%AE%E3%81%BF_WHT-1.png)

![INSIGHT LAB_文字のみ](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/INSIGHT%20LAB_%E6%96%87%E5%AD%97%E3%81%AE%E3%81%BF.png?width=400&height=110&name=INSIGHT%20LAB_%E6%96%87%E5%AD%97%E3%81%AE%E3%81%BF.png)

[![相談・お問い合わせ](https://hubspot-no-cache-na2-prod.s3.amazonaws.com/cta/default/5935783/4871ff46-eca7-4fd2-8f82-565d765c8ad8.png)](https://hubspot-cta-redirect-na2-prod.s3.amazonaws.com/cta/redirect/5935783/4871ff46-eca7-4fd2-8f82-565d765c8ad8)

<https://knowledge.insight-lab.co.jp/tableau/chart/pyramid-chart#tmpmodule_1596100659480207>

- [Tableauとは](https://service.insight-lab.co.jp/Tableau)
- [Tableauナレッジ](https://knowledge.insight-lab.co.jp/tableau)
- [お役立ち資料](https://download.insight-lab.co.jp/tableau/download)
- [研修コース](https://service.insight-lab.co.jp/data-analytics-dojo/training_course)

###### 1 分で読むことができます。

# [【Tableau】バタフライチャートの利用方法](https://knowledge.insight-lab.co.jp/tableau/chart/pyramid-chart)

 執筆者 [BI LAB編集室](https://knowledge.insight-lab.co.jp/tableau/author/bi-lab) 更新日時 2018年12月19日

###### Topics: [チャート作成方法](https://knowledge.insight-lab.co.jp/tableau/tag/チャート作成方法)

![](https://knowledge.insight-lab.co.jp/hubfs/Imported_Blog_Media/26.png)

 目次

この記事は、『Tableau Knowledge Advent Calendar 2018』の第１９回の記事です。  
今日のテーマは『バタフライチャート』です！

## バタフライチャート

バタフライチャートは「年齢」「性別」ごとの人数を可視化する際によく使われる典型的なチャートです。  
今回はTableauでの作り方を解説していきます。

まず、今回使用するのは以下の様な構造のデータです。

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/26.png?width=309&height=415&name=26.png)

### １．年齢のビンを作成する

バタフライチャートでは、年代毎の人数をカウントするので、Tableauではビンを利用します。  
今回は10歳ごとの年代を軸としていきます。

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/27.png?width=446&height=218&name=27.png)

### ２．男女のカウントをする

データの中に性別が入っているので、それを利用して男女それぞれのカウントをしていきます。  
カウント方法は色々と考えられますが、今回は単純にフラグを立てる方法でやってみます。  
以下のような計算フィールドを男女それぞれ作成します。

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/28.png?width=345&height=107&name=28.png)

### ３．チャートを作成する

ここまでで準備はできましたので、チャートを作っていきましょう。  
まずは、以下のように要素を配置します。  
列：合計(男性)、合計(女性)  
行：年齢（ビン）

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/29.png?width=990&height=355&name=29.png)

次に、性別毎に色分けをします。

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/30.png?width=1152&height=451&name=30.png)

形をピラミッドにするため、男性のグラフを反転させます。  
男性の軸を右クリックし”軸の編集”から、”反転”にチャックをつけます。

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/31.png?width=455&height=628&name=31.png)

すると、男性のグラフが反転し、ピラミッドっぽくなってきました。

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/32.png?width=1155&height=449&name=32.png)

最後に、年齢のビンを降順に並び替えると、

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/33.png?width=482&height=487&name=33.png)

バタフライチャートの完成です。

![](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/Imported_Blog_Media/34.png?width=822&height=254&name=34.png)

以上、バタフライチャートでした！

データ利活用のプロに相談してみませんか？

INSIGHT LABでは、Tableauだけではなく、他BI製品含めたご相談を承っております。導入済みのお客様からのご相談も多く頂いております。お気軽に以下よりご相談ください。

[![相談・お問い合わせ](https://hubspot-no-cache-na2-prod.s3.amazonaws.com/cta/default/5935783/4871ff46-eca7-4fd2-8f82-565d765c8ad8.png)](https://hubspot-cta-redirect-na2-prod.s3.amazonaws.com/cta/redirect/5935783/4871ff46-eca7-4fd2-8f82-565d765c8ad8)

- [Tweet](https://twitter.com/share)

![BI LAB編集室](https://knowledge.insight-lab.co.jp/hubfs/image%20(3)-3.png)

#### 執筆者 [BI LAB編集室](https://knowledge.insight-lab.co.jp/tableau/author/bi-lab)

BI LAB（データ活用研究所）編集室です。 BI、AI、DWHなどデータ活用に関するトレンドやニュースやコラムをほぼ毎日配信しています。押さえておきたい基本知識から、最新ニュース、事例インタビューやお役立ち情報・セミナーレポートまで、データ活用の専門家ならではの視点と情報量でお届けします。

###### [前の投稿](https://knowledge.insight-lab.co.jp/tableau/data-source/function_regexp_replace)

[![](https://knowledge.insight-lab.co.jp/hubfs/Imported_Blog_Media/computer_mojibake-2.png)](https://knowledge.insight-lab.co.jp/tableau/data-source/function_regexp_replace)

###### [【Tableau】正規表現関数入門【REGEXP\_REPLACE】](https://knowledge.insight-lab.co.jp/tableau/data-source/function_regexp_replace)

###### [次の投稿](https://knowledge.insight-lab.co.jp/tableau/chart/moving-annual-total)

[![移動年計](https://knowledge.insight-lab.co.jp/hubfs/Imported_Blog_Media/38.png)](https://knowledge.insight-lab.co.jp/tableau/chart/moving-annual-total)

###### [Tableauで移動年計を作成する方法](https://knowledge.insight-lab.co.jp/tableau/chart/moving-annual-total)

RECOMMEND こちらの記事も人気です。

<https://knowledge.insight-lab.co.jp/tableau/tableau-keisanfield10>

###### 6 分で読むことができます。

#### [Tableau 計算フィールド活用術：実務で使える計算式10選とその用途](https://knowledge.insight-lab.co.jp/tableau/tableau-keisanfield10)

###### 2025年 6月 24日

<https://knowledge.insight-lab.co.jp/tableau/data-source/function_datetrunc>

###### 1 分で読むことができます。

#### [【Tableau】日付関数入門【DATETRUNCで日付を特定の日付単位に丸める】](https://knowledge.insight-lab.co.jp/tableau/data-source/function_datetrunc)

###### 2018年 12月 9日

<https://knowledge.insight-lab.co.jp/tableau/tableau-data-source-replacement-method>

###### 2 分で読むことができます。

#### [【Tableau】データソースの置換手順 (Tableau Certified Data Analyst 出題範囲)](https://knowledge.insight-lab.co.jp/tableau/tableau-data-source-replacement-method)

###### 2024年 5月 19日

##### 運営会社

運営会社

- [会社概要](https://www.insight-lab.co.jp/about/company.html)
- [運営責任者](https://twitter.com/Kajiwara81)
- [お問い合わせ](https://contact.insight-lab.co.jp/main)

##### メニュー

メニュー

- Tableauとは
- [Tableau技術ナレッジ](https://knowledge.insight-lab.co.jp/tableau)
- Tableau研修
- [お役立ち資料](https://download.insight-lab.co.jp/tableau/download)

[![INSIGHT LAB](https://knowledge.insight-lab.co.jp/hs-fs/hubfs/INSIGHT%20LAB_%E6%96%87%E5%AD%97%E3%81%AE%E3%81%BF_WHT-1.png?width=200&height=55&name=INSIGHT%20LAB_%E6%96%87%E5%AD%97%E3%81%AE%E3%81%BF_WHT-1.png "INSIGHT LAB")](https://www.insight-lab.co.jp/)

- [プライバシーポリシー](https://www.insight-lab.co.jp/privacy.html)

Copyright © 2020 INSIGHT LAB, Inc.

<https://twitter.com/INSIGHTLAB_INC><https://www.youtube.com/@insightlab2105>