Forum Discussion
Clustered Column Chart - Grouping by same month over years?
- 9 years ago
Alternatively you can drag your Date field to the Axis and keep only the MONTH from the resulting Hierarchy
then drag your Date field again but this time to the Legend and keep only the YEAR
and finally place your Measure (which won't need any adjustments now because of the Legend) in the Value
If you have many years - you can limit what shows on the chart with a Slicer or some type of filter limiting the years
One thing to note about this approach is that it will let you compare months of different years not only consecutive years
for example Monthly data in 2016 vs monthly data in 2012 only
Like this...
Hope this helps! :smileyhappy:
Hi pe2950
I created some dummy data by creating the following calculated table...
Table = SELECTCOLUMNS(
CALENDAR(DATE(2016,1,1),TODAY()),
"Start Of Month" , DATE(
YEAR([Date])
,MONTH([Date]),
1),
"Lead Count" , INT(RAND() * 100) )This just creates a two column table with a bunch of random numbers for the Lead Count.
I then added the following measure
Lead Count Last Year = CALCULATE(
SUM('Table'[Lead Count]),
SAMEPERIODLASTYEAR('Table'[Start Of Month])
)I could then create the following chart.
This is assuming you have just two years worth of data. What if you have more than two? Same Period Last Year will no longer work... What might then?