5 Replies Latest reply on Jul 3, 2017 8:53 AM by user29536

# Having trouble with percent (average)

Having trouble with percent (average) see photo

• ###### 1. Re: Having trouble with percent (average)

I think you'll have to start by explaining what you mean by "average (percentage) for each diagnostic per case"

Run through an example showing how the numbers you've shown us need to be used to arrive at the answer you want.

• ###### 2. Re: Having trouble with percent (average)

If you could, also explain how you arrived at those numbers.

Are they summary fields?

Is this  a sub summary report?

Where do you want to see the numbers?  I assume if you're looking for something like:

20%   2-CT Scan

10%   1-Cat Scan

10%   1-MRI

20%   2-Ultrasound

40%   4-X-Ray

100%

Your numbers 2,1,1,2,4 are coming from summaries in a sub-summary report.  If so then the percentage numbers can come from the GetSummary function.

Or are those numbers in a portal of related records?

• ###### 3. Re: Having trouble with percent (average)

Average is the result of (Total all items) / (Number of Items)

Therefore to get an average of 100% every item would have to be 100%. or item/item

Using the term average is incorrect, therefore.

SteveMartino provides a good question.

Perhaps what you want is a total of the averages which you could get by sum(calcaveragefield) but due to the nature of computer computations you might not get 100% but reasonably close.

• ###### 4. Re: Having trouble with percent (average)

There are 8 claims, of those 8 claims there were 11 visits against the claims. On each visit there is a possibility of 2 diagnostics per visits. So a possible 22 diagnostics ordered. I use a list to get the diagnostics and a pattercount to get the number. As you can see in the field.

So of the

2-CT Scan

1-Cat Scan

1-MRI

2-Ultrasound

4-X-Ray

these represent the 10 of the possible 22 diagnostics on the 11 visits. This is 45.5%

Leaving 55% for Non Ordered.

Here's the even harder part. Since there is only 8 cases. my task is to come up with the average or

percentage of diagnostics per case.

• ###### 5. Re: Having trouble with percent (average)

this works.

Pad ( "None Ordered"; "_" ; 15 ; "left" ) & Round((OCCNow Visits::Sum_Number_Visits * 2 -  OCCNow Visits::Sum_Diagnostics_Qtr_Count) / (OCCNow Visits::Sum_Number_Visits * 2 );2) & ¶ &

Pad ( "CT Scan"; "_" ; 17 ; "left" ) & (1- Round((OCCNow Visits::Sum_Number_Visits * 2 -  OCCNow Visits::Sum_Diagnostics_Qtr_Count) / (OCCNow Visits::Sum_Number_Visits * 2 ) ;2))  * PatternCount( List(OCCNow Visits by Employer Qtr::Diagnostic Study List) ; "CT Scan") * .1 & ¶ &

Pad ( "CAT Scan"; "_" ; 17 ; "left" ) & (1- Round((OCCNow Visits::Sum_Number_Visits * 2 -  OCCNow Visits::Sum_Diagnostics_Qtr_Count) / (OCCNow Visits::Sum_Number_Visits * 2 ) ;2))  * PatternCount( List(OCCNow Visits by Employer Qtr::Diagnostic Study List) ; "CAT Scan") * .1 & ¶ &

Pad ( "MRI"; "_" ; 17 ; "left" ) & (1- Round((OCCNow Visits::Sum_Number_Visits * 2 -  OCCNow Visits::Sum_Diagnostics_Qtr_Count) / (OCCNow Visits::Sum_Number_Visits * 2 ) ;2))  * PatternCount( List(OCCNow Visits by Employer Qtr::Diagnostic Study List) ; "MRI") * .1 & ¶ &

Pad ( "Ultrsound"; "_" ; 17 ; "left" ) & (1- Round((OCCNow Visits::Sum_Number_Visits * 2 -  OCCNow Visits::Sum_Diagnostics_Qtr_Count) / (OCCNow Visits::Sum_Number_Visits * 2 ) ;2))  * PatternCount( List(OCCNow Visits by Employer Qtr::Diagnostic Study List) ; "Ultrasound") * .1 & ¶ &

Pad ( "X-Ray"; "_" ; 18 ; "left" ) &(1- Round((OCCNow Visits::Sum_Number_Visits * 2 -  OCCNow Visits::Sum_Diagnostics_Qtr_Count) / (OCCNow Visits::Sum_Number_Visits * 2 ) ;2))  * PatternCount( List(OCCNow Visits by Employer Qtr::Diagnostic Study List) ; "X-Ray") * .1

resulting in.

None Ordered ___.55

CT Scan________.09

CAT Scan_______.045

MRI____________.045

Ultrsound _______.09

X-Ray__________.18