Events
31 Mar, 23 - 02 Apr, 23
The biggest Fabric, Power BI, and SQL learning event. March 31 – April 2. Use code FABINSIDER to save $400.
Register todayThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Applies to:
Calculated column
Calculated table
Measure
Visual calculation
Returns a sample subset from a Table that is obtained by plotting the rows as points in 2D space and removing overlapping points.
SAMPLECARTESIANPOINTSBYCOVER(<Size>, <Table>, <XAxis>, <YAxis>[, <Radius>] [, <MaxMinRatio>] [, <MaxBlankRatio>] )
Term | Definition |
---|---|
Size | Number of rows in the sample to return |
Table | Any DAX expression that returns a table of data from where to return a sample subset from. |
XAxis | The numerical XAxis column from the Table. |
YAxis | The numerical YAxis column from the Table. |
Radius | (Optional) The numerical Radius column from the Table. |
MaxMinRatio | (Optional) When Radius is specified, MaxMinRatio has to be specified and defines the ratio between the maximum and the minimum radiuses of drawn points. See remarks for more details. |
MaxBlankRatio | (Optional) When Radius is specified, MaxBlankRatio has to be specified and defines the ratio between the maximum and blank radiuses of the drawn points. See remarks for more details. |
The sample from Table consisting of Size number of rows.
If Size is less than or equal to 0, SAMPLECARTESIANPOINTSBYCOVER returns an empty table
If Radius is specified, MaxMinRatio and MaxBlankRatio need to be specified and set to a value larger than 1. If not, SAMPLECARTESIANPOINTSBYCOVER returns an error
Set MaxMinRatio to the maximum of Radius divided by the minimum of Radius. For example, if the minimum Radius is 20 and the maximum Radius is 60, the MaxMinRatio parameter should be set to 60/20 = 3.
Set MaxBlankRatio to the maximum of Radius divided by the Radius for blank values. For example, if the maximum Radius is 60 and the Radius for blank values is 6, then MaxBlankRatio should be set to 60/6 = 10.
This function is not supported for use in DirectQuery mode when used in calculated columns or row-level security (RLS) rules.
The following DAX query:
EVALUATE
SAMPLECARTESIANPOINTSBYCOVER (
1000,
SELECTCOLUMNS ( Sales, "x", [Unit Price], "y", [Sales Amount] ),
[x],
[y]
)
Returns a 1000 row sample from unique points from the Sales table in a 2D space defined by Unit Price as the X axis and Sales Amount as the Y axis.
Events
31 Mar, 23 - 02 Apr, 23
The biggest Fabric, Power BI, and SQL learning event. March 31 – April 2. Use code FABINSIDER to save $400.
Register today