Custom Formula Collection

Money Flow Index

Taken from Stocks &
Commodities
, V. 12:8 (321-324): SIDEBAR: The Money Flow Index

"The money flow index (MFI) is a volume-weighted form of the relative strength index (RSI). Instead of using up closes versus down closes, the MFI compares today's average price to yesterday's average price and then weighs the average price by volume to calculate money flow (MF). The ratio of the summed positive and negative money flows are then normalized to be on a scale of zero to 100."

Here are the MetaStockTM formulas for the Money Flow Index:

Positive Money Flow:
sum ( if ( typ( ) ,>
,ref ( typ ( ) ,-1 ) ,V * typ ( ) ,0 ) , PERIODS)

Negative Money Flow:
sum ( if ( typ( ) ,<
,ref ( typ( ) ,-1) ,V * typ ( ) * -1 ,0 ) , PERIODS)

Money Flow Ratio:
fml ( "Positive Money Flow" ) / fml ( "Negative Money Flow" )

Money Flow Index:
100 - ( 100 / ( 1 + fml ( "Money Flow Ratio" ) ) )

***The time periods are controlled by PERIODS in the Positive and Negative Money Flow formulas.

For additional help with formulas, please see the Formula Primer.

Can't find the custom formula you need? MetaStock can create formulas for you.