From what i understood is, u have data year and month wise.. u need to show data year wise with a condition that the year dont have data for all the 12 months..
groupd by data by year and count the number of months available for all years..
then set a flag for the years that dont have data for all 12 months all the above steps in script.
Then in ui write a calculated dimension or set alternate state to show only years that have a flag..
If this is now what u require, pls explain..