Jump to content
  • 0

Aggregation calculation for Standard deviation over a time period ex weekly)


Sergioleno1

Question

I use the available aggregation function Average to calculate an average production rate on a weekly basis.  Is there a function or formulae to do the same thing meaning to measeare the standard deviation on a weekly basis.  Also would like to use the same function for different aggregation time span week, month, year.

Also if possible would like to see both lines (average and standard deviation) on the same graph. 

Thanks.

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

Hello @Sergioleno1,

As I understand from your request, you are referring to the Chart DataPage. 

Since there is no STDEV() function in the list of the Aggregate functions on the Chart DataPages, you may try to create Combined Chart and Report DataPage.

1) Let`s say there is a table with the following design:

FPP7x8v.png

2) In the DataPage, in the 'Configure Results Page Fields' add the Calculated field with the SELECT statement:

XPjPyKc.png

SELECT STDEV(Value_field) FROM Chart_STDEV WHERE DatePart(wk, Date) = DatePart(wk, target.[@field:Date])

Replace field names and table name. 

 

3) The 'Configure Chart Options' page should have the following settings

* Data Source Settings:

LPUjp1W.png

* Category (X Axis)

vc26pg3.png

* Values (Y Axis)

7NUJWsy.png

 

4) The result:

XlnA0qM.png

5) It`s possible to hide the results (if needed) by using CSS in the Header section on the  'Configure Results Page Fields' page:

<style>
table[id*='cbTable'] {
display: none;
}
</style>

Do not forget to disable the HTML editor on the Advanced tab before pasting.

l16Hyj4.png

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...