Home : Products : Hach WIMS : Hach WIMS Client : Documentation : Function Reference : Math Toolbox Functions : MTHMOVn
Q10869 - INFO: MTHMOVn

MTHMOVn returns and n day moving average; however, it skips the first 6 days of each month.

SYNTAX:

MTHMOVn(Cx)
where :
Cx is a conditional variable x
n specifies the number of days to average as a moving average. For daily detail variables, this specifies the number of slots (i.e., hours for hourly variables).

NOTES:

n must be between 1 and 100 

This function requires the target and source variable frequencies to match. E.g. Hourly target variable = Hourly source variable, 5-Minute Target variable = 5-Minute Source Variable. If the frequencies do not match, the function will return incorrect values. 

EXAMPLE 1: Return the 7 day Moving Average starting on the 7th day for a daily variable.

Source variable (71) is set to Daily and Target variable (115) is also set to Daily. Because both the Source and Target variables are the same (Daily), the time increment BYDAY will be used.

V121 = MTHMOV7(C70)

Variable 121 will be a 7 day moving average of variable 70, with days 1-6 of each month left blank (NULL):

 

Example 2: Return the seven hour Moving Average starting on the 7th day from an hourly variable.

Source variable (4714) is set to Hourly and Target variable (4715) is set to Hourly.

V4714 - Is a hourly parameter
V4715 - Is a hourly calculation

V4715 = MTHMOV7(V4714)

Our results will be as follows:

See: Working with Daily Detail Variables in Calculations.

Related Articles
No Related Articles Available.

Article Attachments
No Attachments Available.

Related External Links
No Related Links Available.
Help us improve this article...
What did you think of this article?

poor 
1
2
3
4
5
6
7
8
9
10

 excellent
Tell us why you rated the content this way. (optional)
 
Approved Comments...
No user comments available for this article.
Created on 4/3/2008 12:50 PM.
Last Modified on 2/11/2015 12:18 PM.
Last Modified by No Author Name Available!.
Article has been viewed 3816 times.
Rated 0 out of 10 based on 0 votes.
Print Article
Email Article