Question: Write a function that moveAve that takes two inputs: a numerical vector (vecIn) and a number(l) corresponding to the length of the exponential moving average.
Write a function that moveAve that takes two inputs: a numerical vector (vecIn) and a number(l) corresponding to the length of the exponential moving average. The output is a vector containing the exponential moving average values. The first value in your exponential moving average should be the simple average of the first l values of vecIn.
Please write in Matlab format!
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
