One formula in Matlab.

2 visualizaciones (últimos 30 días)
Artyom
Artyom el 17 de Jul. de 2012
Hi everyone. Is there any function in Matlab that can easily calculate such kind of formula (Y[i]-Y[i-1])/Y[i-1] ?

Respuesta aceptada

Walter Roberson
Walter Roberson el 17 de Jul. de 2012
No. However, you can use
diff(Y) ./ Y(1:end-1)

Más respuestas (0)

Categorías

Más información sobre Statistics and Machine Learning Toolbox en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by