How to Filter Rows and Columns in Visualizations and Tables without Code
This blog post will take you through the built-in row and column manipulation settings in our R-based Visualizations and Paste/Enter Table outputs for filtering data.
In Displayr you can manipulate rows and columns directly in any Visualization or Paste/Enter Table output created via the Insert menu.
This allows you to choose what table dimensions should be included in the final output without having to make changes to the source table. If you wish to display a table instead, referencing your source table via a Paste Table (Autofit) R output provides the same manipulation options.
Let's now go through the different types of filtering possible under the Inputs > ROW MANIPULATIONS and COLUMN MANIPULATIONS sections of these outputs.
Remove rows and columns with no data or small sample size
1. Hide empty rows/columns
This option removes any row or column that has no data in it.
2. Hide rows/columns with small sample sizes
Instead of only removing blank data, you can also specify a Sample size cut-off to remove rows and columns that do not meet this threshold. Note that the statistic used for sample size will be based on your source table, so Column Sample Size, Column n, Sample Size, or Base n must be included.
Display fixed rows and columns
3. Select rows/columns to show by > Type row names or indices
If you wish to show only specific rows/columns then you can list either the name or index number of the desired row/column under Rows/Columns to show, separating each item by a comma.
4. Rows/Columns to ignore
By default, NET, Total, and SUM are set to be ignored from your output but you can change this or add to the list by referencing the name of the row/column, again separating each item by a comma.
Display dynamically selected and auto-updating rows and columns
5. Select rows/columns to show by > Choosing from Combo Box or List Box control
When you have numerous brands or statements in a table, you often want to let the viewer select the items they are interested in via a Combo Box or List Box. This option will work seamlessly with any visualization or pasted table output when you select the appropriate control box under Rows/Columns to show. The result will be an output that automatically changes what data is displayed based on the user selections.
6. Number of rows/columns from top/left to show
If you have additional rows/columns in your source table and only want to show the first 6, for example, then setting this to 6 will always show these rows/columns even if your data updates. In this example, only 'Coca-Cola' to 'Pepsi Max' have been included from the table rows.
7. Number of rows/columns from bottom/right to show
This option is the same as the above but works the opposite way. If you have quarterly time series data and you want to only show the last 2 quarters i.e. the last 2 columns of your table, setting this to 2 will restrict the output to only show these columns. If your data then updates with additional months, this option will automatically adjust.