If you are not already doing this, create a formula in the subreport and place it in the subreport report footer:
whileprintingrecords;
shared currencyvar aveprice := average({table.sellingprice});
Then in the main report in a section below the one in which the subreport is located (i.e. GH_b if the sub is in GH_a), add a formula like this:
whileprintingrecords;
shared currencyvar aveprice;
shared currencyvar sumave;
sumave := sumave + aveprice;//accumulates the average
aveprice;//displays the average at the group level
Then in the report footer, add this formula:
whileprintingrecords;
shared currencyvar sumave;
If the sub can be null, you should have a reset formula for the shared variable:
whileprintingrecords;
shared currencyvar aveprice := 0;
Place this in the report header and in the group footer section.
If your price is actually a number, not a currency, change all references to currencyvar in the formulas above to numbervar.
-LB