Moving window mechanism is prevailingly adopted to deal with the serial correlations of sample data in the applications of data-driven methods for fault detection and diagnosis, such as dynamic principle component analysis, dynamic Fisher discriminant analysis and so on. Before preparing the data set for subsequent processing, it is very important to determine a suitable size of a moving window, as it potentially determines both the identification delay and the identification rate. For enhancing safety and achieving more economic benefits for the operation of nuclear power plants, it is very important to timely (i.e., to make the identification delay as short as possible) and correctly (i.e., to make the identification rate as high as possible) identify the transients. Therefore, this study investigates the effect of the size of moving window to identification result and proposes an algorithm to obtain the optimal size of a moving window. The proposed algorithm was verified to be effective to find out an optimal size, based on which the shortest identification delay and highest identification rate could be achieved. Moreover, the investigation results also showed the trend of the effect of the signal-to-noise rate (SNR) to the selection of optimal moving window size. The verifications were carried out using our previously proposed identification method based on linear representation and the sample data were from the simulator of Chinese High Temperature gas-cooled Reactor Pebble-bed Module (HTR-PM) project.