I am new to Business Objects and more specifically Desktop Intelligence. We are trying to use it as a reporting tool for our scientific data but running into issues when performing calculations to “create” objects and then trying to perform statistical or aggregate functions on them. For example I run a query that pulls the columns subject name, result day, parameter, and result value. In a table it would look like this:
SUBJECT DAY PARAM RV
10001 0 Length 5.32
10001 0 Width 4.68
10002 0 Length 3.98
10002 0 Width 1.64
10001 7 Length 8.89
10001 7 Width 7.30
10002 7 Length 4.17
10002 7 Width 2.19
We then use the equation for Volume: L*W^2*0.52 in the report defined as measure variable. Using a cross tab with days across the top and subjects down the side I display Length Width and Tumor Volume like such:
0 7
SUBJECT L W V L W V
10001 5.32 4.68 60.59 8.89 7.30 246.35
10002 3.98 1.64 5.57 4.17 2.19 10.40
COUNT # #
MEAN # #
Within the footers I’d like to display aggregates such as count, standard deviation, percent change from day zero but they are all screwed up. It’s not that it’s also doubling the n by two either to account for the fact that Length and Width make up Volume. I have no clue and am at a loss. Any advice suggestions or guidance would be welcomed.
Thanks in advance,
Jeff
I assume that your cross tab looks like the following in Slice and Dice:
¦ <DAY> (Break) ¦ <PARAM> -------------------- <SUBJECT> ¦ <RV>So your table should look something like:
0 7 Length Width Volume Length Width Volume 10001 5.32 4.68 60.59 8.89 7.30 246.35 10002 3.98 1.64 5.57 4.17 2.19 10.40With
<DAY>‘s break footer having the volume variable.For your volume calculation I’ve used the formula:
=(<RV> Where (<PARAM>="Length"))*(Power(<RV> Where (<PARAM>="Width") , 2))*0.52Right click on the cross tab edge and select
Format Crosstab...Then check theShow Footercheck box in theDown Edge Displaysection of theGeneraltab. Add extra rows in the footer if you need them.Then manually add the formulas for count
=Count(<VOLUME>)and mean=Average(<VOLUME>)For me the final table now looks like this (With values rounded to 2dp):
0 7 Length Width Volume Length Width Volume 10001 5.32 4.68 60.59 8.89 7.30 246.35 10002 3.98 1.64 5.57 4.17 2.19 10.40 Count 2.00 2.00 Mean 33.08 128.37The trick is making sure the calculations happen in the right context (that is, with respect to the header variables in the different sections of the table). You can add and remove variables and context with the functions
In,ForAllandForEach. Although I haven’t needed to use them for this table.