Create new tables with subsets of your data using the Pivot table in LibreOffice

Just accidentally discovered this nifty feature in Calc of Libreoffice allowing to quickly create sub-sets of your data by double clicking on the row or column totals in a Pivot table. Suppose you have a table with variables var1 and var2 and values in column C. Variable A has four classes a-d, variable B has three classes 1-3. Let’s create a pivot table of the variables A against B.

Now, if you click on a row total, of e.g., row ‘b’, a new sheet and table will be created containing all values from the original table where var1 = ‘b’ (Figure 2)

Double clicking a column total or the total of both (lower right cell of your pivot table) works the same. In the example below, I first filter out var1=b and var2=2. Clicking on the table total will give a new table with the records from the original table with var1=b and var2=2 filtered out.

This feature is a nice alternative way to filter your data and I probably will end up using this more often.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s