Power BI 服務中的交叉分析篩選器 (教學課程)Slicers in Power BI service (Tutorial)

您的銷售副總裁希望能夠查看整個部門和各分區經理的多項指標。Your VP of Sales wants to be able to look at a number of metrics, for the entire division and for each individual District Manager. 她可以為每個經理分別建立報表頁面,或者可以使用交叉分析篩選器。She could create a separate report page for each manager, or she could use a slicer. 交叉分析篩選器會縮小頁面上其他視覺效果中顯示的資料集部分。A slicer narrows the portion of the dataset shown in the other visualizations on the page. 交叉分析篩選器是篩選的替代方式。Slicers are an alternate way of filtering.

使用交叉分析篩選器的時機When to use a slicer

交叉分析篩選器在下列情況中是絕佳選擇。Slicers are a great choice in the following situations.

  • 在報表畫布上顯示常用或重要篩選,以方便存取。To display commonly-used or important filters on the report canvas for easier access.
  • 讓您不需要開啟下拉式清單尋找篩選詳細資料,即可輕鬆查看目前篩選的狀態。To make it easier to see the current filtered state without having to open a drop-down list to find the filtering details.
  • 如果您想隱藏不需要但仍可用以篩選的資料列,這能讓資料表變得更簡潔、清楚。When you want to hide columns you don't need but still be able to use them to filter - this makes for narrower, cleaner tables.
  • 建立更容易聚焦的報表 - 由於交叉分析篩選器是浮動物件,您可以將其放在報表上精彩部分的旁邊,引導您的使用者聚焦於此。To create more focused reports - since slicers are floating objects you can put them next to the interesting part of the report you want your users to focus on.

建立交叉分析篩選器Create a slicer

  1. 編輯檢視中開啟零售分析範例,然後新的報表頁面Open the Retail Analysis Sample in Editing View and add a new report page.
  2. 從 [欄位] 窗格中選取 [區域] > [區域經理]。From the Fields pane, select District > District Manager.

  3. 將視覺效果轉換成交叉分析篩選器。Convert the visualization to a slicer. 在 [視覺效果] 窗格中選取交叉分析篩選器圖示。In the Visualizations pane, select the slicer icon.

設定交叉分析篩選器的格式Format the slicer

  1. 在已選取交叉分析篩選器的情況下,在 [視覺效果] 窗格中選取滾筒刷圖示 ,以顯示 [格式] 選項。With the slicer selected, in the Visualizations pane, select the paint roller icon to display the Format options.
  2. 選取 [一般] > [外框色彩],然後選擇深藍色,並將 [寬度] 變更為 6Select General > Outline color and choose dark blue and change the Weight to 6.

  3. 在 [選取控制項] 下,[全選] 預設為 [關閉] ,而 [單選] 預設為 [開啟] 。Under Selection Controls, by default, Select All is Off and Single Select is On. 這表示必須使用 CTRL 鍵才能同時選取多個名稱。This means that I have to use the CTRL key to select more than one name at a time. 請將 [全選] 改成 [開啟] ,[單選] 改成 [關閉] 。Turn Select All to On and Single Select to Off.

    • 請注意,交叉分析篩選器的清單頂端現在出現了 [全選] 選項。Notice that the slicer now has a Select All option at the top of the list. 切換 [全選] 以選取所有名稱,或不選取任何名稱。Toggle Select All to select all of the names or to select none of the names.
    • 而且您現在不需要使用 CTRL 鍵,就可以選取多個名稱。And you can now select more than one name without having to use the CTRL key.
  4. 在 [項目] 下,將文字大小放大到 14 pt。Under Items, increase the text size to 14pt. 我們想要確保同事注意到此交叉分析篩選器。We want to be sure that our colleagues notice this slicer.
  5. 最後,將 [字型色彩] 設為深紅色。Lastly, set Font color to a dark red. 這樣就能從交叉分析篩選器中未選取的名稱,將已選取的名稱區別出來。This will distinguish the selected names from the unselected names in our slicer.

  6. 好好探索交叉分析篩選器適用的其他選項吧。Have fun exploring the other options available for slicers.

在報表中使用交叉分析篩選器Use the slicer in a report

  1. 將其他幾個視覺效果新增至報表頁面,或開啟零售分析範例報表並選取 [區域每月銷售額] 索引標籤。Add some additional visualizations to the report page or open the Retail Analysis sample report and select the District Monthly Sales tab.

  2. 切割 Carlos 的報表頁面。Slice the report page for Carlos. 請注意其他視覺效果如何更新以反映這些選取項目。Notice how the other visualizations update to reflect these selections.

  3. 依照區域經理的姓氏,以字母順序來排序交叉分析篩選器。Sort the slicer alphabetically by District Manager last name. 選取交叉分析篩選器右上角的省略符號 (...),然後選擇 [區域經理] 。Select the ellipses (...) in the top right corner of the slicer and choose District Manager.

控制交叉分析篩選器對頁面上其他視覺效果的作用Control what effect the slicer has on other visuals on the page

您想要讓交叉分析篩選器只篩選報表頁面上的某些視覺效果嗎?Do you want the slicer to only filter some of the visuals on the report page? 使用 [視覺效果互動] 控制項可對此進行設定。Use the Visual interactions control to set this up.

注意:如果您沒有看到 [視覺效果互動],請改為尋找其圖示 NOTE: If you don't see Visual Interactions, look for its icon instead . 如果兩者都沒看到,請確認您已進入報表編輯檢視If you don't see either, make sure you are in report Editing view.

  1. 選取 [交叉分析篩選器] 加以啟動,並從功能表列選擇 [視覺效果互動]。Select the slicer to make it active and, from the menu bar, choose Visual interactions.

  2. 篩選控制項會出現在頁面上其他所有視覺效果的上方。Filter controls will appear above all the other visuals on the page. 如果交叉分析篩選器應篩選某個視覺效果,請選取 [篩選] 圖示。If the slicer should filter a visual, select the Filter icon. 如果交叉分析篩選器不應對該視覺效果產生任何作用,請選取 [無] 圖示。If the slicer should have no effect on the visual, select the None icon.

如需詳細資訊,請參閱在 Power BI 報表中與視覺效果互動For more information, see Visual interactions in a Power BI report.

Power BI 中的考量和對交叉分析篩選器進行疑難排解Considerations and troubleshooting slicers in Power BI

在 Power BI 中使用交叉分析篩選器有以下限制︰There are a few limitations to using slicers in Power BI, which are the following:

  1. 交叉分析篩選器不支援輸入欄位。Slicers do not support input fields.
  2. 單一的交叉分析篩選器無法用於整份報表。A single slicer cannot be used across an entire report. 交叉分析篩選器只會影響目前的頁面。A slicer only impacts the current page.
  3. 交叉分析篩選器無法釘選到儀表板。Slicers cannot be pinned to a dashboard.
  4. 交叉分析篩選器不支援向下鑽研。Drilldown is not supported for slicers.
  5. 交叉分析篩選器不支援視覺效果等級篩選。Slicers do not support Visual level filters.

您對如何改進 Power BI 有任何想法嗎?Do you have ideas for how to improve Power BI? 送出想法Submit an idea.

後續步驟Next steps

將視覺效果新增至報表Add a visualization to a report

Power BI 中的視覺效果類型Visualization types in Power BI

Power BI - 基本概念Power BI - Basic Concepts

請試用 - 完全免費!Try it out -- it's free!

有其他問題嗎?More questions? 試試 Power BI 社群Try the Power BI Community