added dynamic lag analysis