It is possible to display aggregate data for groups that are not explicitly being broken out in your report.
#compares months to their respective years, although 'year' is not explicitly being reported on{|RESULT|}
<table>
<thead>
<tr>
<th>Month</th>
<th>Score</th>
<th>Compared to Year</th>
</tr>
</thead>
<tbody>
{|LOOP|RESULT.MONTH_YEAR(SORT=ORDER_NUM)}
<tr>
<th>{MONTH_YEAR.NAME}</th>
<td>{AVG(MONTH_YEAR.SCORE).NUMBERFORMAT(2)}</td>
<td>{CALC(AVG(MONTH_YEAR.SCORE) - AVG(MONTH_YEAR.SCORE,YEAR)).NUMBERFORMAT(2)}</td>
</tr>
{/|LOOP|}
</tbody>
</table>
{/|RESULT|}
#compares each datapoint's score to the average score for the month the datapoint was done in
{|RESULT|}
<table>
<thead>
<tr>
<th>ID</th>
<th>Score</th>
<th>Avg Month Score</th>
<th>Compared to Month</th>
</tr>
</thead>
<tbody>
{|LOOP|RESULT.DATAPOINTS(SORT=TRENDING_TIMESTAMP)}
<tr>
<th>{DATAPOINTS.ID}</th>
<td>{DATAPOINTS.SCORE}</td>
<td>{AVG(DATAPOINTS.SCORE, MONTH_YEAR).NUMBERFORMAT(2)}</td>
<td>{CALC(DATAPOINTS.SCORE - AVG(DATAPOINTS.SCORE, MONTH_YEAR)).NUMBERFORMAT(2)}</td>
</tr>
{/|LOOP|}
</tbody>
</table>
{/|RESULT|}
#ranks datapoints in the months they fall in
{|RESULT|}
<table>
<thead>
<tr>
<th>ID</th>
<th>Score</th>
<th>Month</th>
<th>Rank in Month</th>
</tr>
</thead>
<tbody>
{|LOOP|RESULT.DATAPOINTS(SORT=TRENDING_TIMESTAMP)}
<tr>
<th>{DATAPOINTS.ID}</th>
<td>{DATAPOINTS.SCORE}</td>
<td>{DATAPOINTS.MONTH_YEAR.NAME}</td>
<td>{RANK(DATAPOINTS.SCORE, DESC, MONTH_YEAR)}</td>
</tr>
{/|LOOP|}
</tbody>
</table>
{/|RESULT|}
#nest day of week within month-year, and also display year average for months
{|NESTED|}
<table>
<tbody>
{|LOOP|NESTED.MONTH_YEAR(SORT=ORDER_NUM)}
<tr>
<td>{MONTH_YEAR.NAME}</td>
<td>{AVG(MONTH_YEAR.SCORE,MONTH_YEAR).ROUND}</td>
<td>{AVG(MONTH_YEAR.SCORE,YEAR).ROUND}</td>
</tr>
{|LOOP|MONTH_YEAR.DAY_OF_WEEK(SORT=ORDER_NUM)}
<tr>
<td>{DAY_OF_WEEK.NAME}</td>
<td>{AVG(DAY_OF_WEEK.SCORE).ROUND}</td>
<td></td>
</tr>
{/|LOOP|}
{/|LOOP|}
</tbody>
</table>
{/|NESTED|}
Notes:
- It is recommended that groups you use in this way be hierarchically-related to the groups you are reporting on, and that they be of a higher hierarchical level. For example, displaying a YEAR value for a MONTH_YEAR group member is acceptable, because a MONTH_YEAR can belong to one and only one YEAR. However, displaying a YEAR value for a DAY_OF_WEEK would not be, because a DAY_OF_WEEK belongs to multiple YEAR members. Similarly, you could not display DAY_OF_WEEK values for a MONTH_YEAR, because a MONTH_YEAR contains multiple DAY_OF_WEEK members.
- In a CROSSTAB report, NULL cells will not have values for extra groups