2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

[PowerBI] 散布図を用いてポジションマッピングを行う

Last updated at Posted at 2025-04-17

要件

  • 4象限のポジションマップを作成する
  • 4分割する定数線(Constant line)が描画されている
  • 各象の点を異なる色に変更する

手順

1. 恒線の追加

  • 散布図を選択し、Analyticsペインを開く
  • X-Axis Constant Lineを追加し、適切な値を設定
  • 同様にY-Axis Constant Lineを追加

2. 条件列の追加

  • Table viewを開く
  • Column toolsタブから、New columnを開く
  • Column =から始まる計算式に条件(DAX)式(Data Analysis Expressions)を記載する
    DAX
    ColumnName = SWITCH(
        TRUE(), 
        'Table'[X] < 50 && 'Table'[Y] < 50, 1,
        'Table'[X] < 50 && 'Table'[Y] > 50, 2,  
        'Table'[X] > 50 && 'Table'[Y] < 50, 3, 
        'Table'[X] > 50 && 'Table'[Y] > 50, 4 
     )
    
    or
    DAX
    ColumnName = SWITCH(
       TRUE(), 
       'Table'[X] <= 50 && 'Table'[Y] <= 50, 1,
       'Table'[X] <= 50 && 'Table'[Y] > 50, 2,  
       'Table'[X] > 50 && 'Table'[Y] <= 50, 3, 
       'Table'[X] > 50 && 'Table'[Y] > 50, 4 
    )
    
  • Table[X]とTable[Y]には、条件に用いるカラム名を入力する(自動補完有)
  • 保存して、Report viewに戻る

3. 条件付き書式の設定

  • VisualizationsペインのFormatペインでMarkersを選択
  • Colorfx(Conditional formatting)を開く
  • DAX式で指定した条件のRulesを作成する
    image.png
  • OKを押下して、条件を適応する

参考リンク

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?