With the development and application of information technology, it is becoming a new research direction to analyze complex traffic flow based on experimental methods. One of the basic problems is the reproduction of the actual traffic flow in the experiment. Based on the framework of a traffic flow experimental system, this paper proposes an experimental method to reproduce the real traffic flow in virtual environment by giving the observation data of traffic flow in real environment whose system framework includes the nonparametric model of traffic flow and the Bayesian learning algorithm. Subsequently, the experimental method was numerically verified in the scene of traffic flow on signal control. The results show that the method proposed could realize the approximate dynamic traffic flow on signal control in virtual environment.