Statistical modelling and analysis of traffic: a dynamic approach