df.dropNulls { city }.pivotCounts(inward = false) { city }
Input DataFrame: rowsCount = 7, columnsCount = 5

Step 1: DataFrame: rowsCount = 6, columnsCount = 5

Output DataFrame: rowsCount = 6, columnsCount = 9


pivoted.gather { "London".."Tokyo" }.into("city", "population")
Input DataFrame: rowsCount = 6, columnsCount = 9

Step 1: Gather

... showing only top 20 of 30 rows

Output DataFrame: rowsCount = 30, columnsCount = 6

... showing only top 20 of 30 rows