finding average risk score
Hello,
I am trying to find the average risk score across multiple sheets given the criteria of being a risk and being open. I am trying to use an (AVG(COLLECT( but I am getting an invalid operation. Here is what I am trying:
=AVG((COLLECT({CA Risk Score}, {CA ROI Option}, "Risk", {CA Risk Status}, "Open") + COLLECT({CRV Risk Score}, {CRV ROI}, "Risk", {CRV Risk Status}, "Open") + COLLECT({HA Risk Score}, {HA ROI}, "Risk", {HA Risk Status}, "Open") + COLLECT({LEE Risk Score}, {LEE ROI}, "Risk", {LEE Risk Status}, "Open") + COLLECT({SSC Risk Score}, {SSC ROI}, "Risk", {SSC Risk Status}, "Open") + COLLECT({DTIM Risk Score}, {DTIM ROI}, "Risk", {DTIM Risk Status}, "Open")))
Best Answer
-
Try wrapping each of the individual AVG(COLLECT(....)) pieces in their own IFERROR function to output a zero in those instances where a sheet does not contain any matching rows.
Then you can wrap the whole thing in another IFERROR for when none of the sheets contain any rows to be included.
Come see me in Seattle at ENGAGE 2024! I will be at the 10xViz partner booth throughout as well as the "Lets Talk About Community" Meet & Eat table on Tuesday from 11:45am - 12:45pm!
Answers
-
Try this instead:
AVG(AVG(COLLECT({CA Risk Score}, {CA ROI Option}, "Risk", {CA Risk Status}, "Open")), AVG(COLLECT({CRV Risk Score}, {CRV ROI}, "Risk", {CRV Risk Status}, "Open")), AVG(COLLECT({HA Risk Score}, {HA ROI}, "Risk", {HA Risk Status}, "Open")), AVG(COLLECT({LEE Risk Score}, {LEE ROI}, "Risk", {LEE Risk Status}, "Open")), AVG(COLLECT({SSC Risk Score}, {SSC ROI}, "Risk", {SSC Risk Status}, "Open")), AVG(COLLECT({DTIM Risk Score}, {DTIM ROI}, "Risk", {DTIM Risk Status}, "Open")))
Come see me in Seattle at ENGAGE 2024! I will be at the 10xViz partner booth throughout as well as the "Lets Talk About Community" Meet & Eat table on Tuesday from 11:45am - 12:45pm!
-
Hey @Paul Newcome. Thank you! I get a #DIVIDE BY ZERO error I think because one of the sheets does not have anything that match the criteria. do you know how I could resolve this?
-
Try wrapping each of the individual AVG(COLLECT(....)) pieces in their own IFERROR function to output a zero in those instances where a sheet does not contain any matching rows.
Then you can wrap the whole thing in another IFERROR for when none of the sheets contain any rows to be included.
Come see me in Seattle at ENGAGE 2024! I will be at the 10xViz partner booth throughout as well as the "Lets Talk About Community" Meet & Eat table on Tuesday from 11:45am - 12:45pm!
-
@Paul Newcome Thank you! That worked. Now I would like exclude zeros from being part of the average calculation... I tried doing this and it didnt work:
=IFERROR(AVERAGEIF(COLLECT({CA Risk Score}, {CA ROI Option}, "Risk", {CA Risk Status}, "Open")>0), 0)
-
You would still use an AVG/COLLECT combo (not the AVERAGEIF function), and you would include a range/criteria set where the range is the score range and the criteria is greater than zero.
Come see me in Seattle at ENGAGE 2024! I will be at the 10xViz partner booth throughout as well as the "Lets Talk About Community" Meet & Eat table on Tuesday from 11:45am - 12:45pm!
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 62.9K Get Help
- 378 Global Discussions
- 208 Industry Talk
- 440 Announcements
- 4.5K Ideas & Feature Requests
- 139 Brandfolder
- 129 Just for fun
- 130 Community Job Board
- 449 Show & Tell
- 30 Member Spotlight
- 1 SmartStories
- 289 Events
- 33 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!