Documentation

@kanunilabs/pivotgrid-enterprise


@kanunilabs/pivotgrid-enterprise / transposeChartResult

Function: transposeChartResult()

transposeChartResult(result, blankLabel?, colors?): ChartTransformResult

The same chart with categories and series swapped (rival analysis, charts §E.1 #13): each series becomes a category and each category a series — "revenue and cost per region" read as "each region's revenue and cost". Nothing is computed again.

The categories' row paths go (a click on a measure filters nothing), and so does the measure behind each series unless every old series had the same one — that is what formats the values. At most DEFAULT_MAX_SERIES categories become series; beyond that the result says the series were cut.

Parameters

result

ChartTransformResult

blankLabel?

string = ''

colors?

readonly string[] = CHART_COLORS

Returns

ChartTransformResult