The interplay between spectator and participant matter in heavy-ion collisions is investigated within the isospin-dependent quantum molecular dynamics (IQMD) model in terms of the rapidity distribution of light charged particles. The effect of different types and sizes of rapidity distributions is studied in elliptical flow. The elliptical-flow patterns show the important role of nearby spectator matter on the participant zone. This role is further explained on the basis of the passing time of the spectator and the expansion time of the participant zone. The transition from in-plane to out-of-plane emission is observed only when the mid-rapidity region is included into the rapidity bin. Otherwise no transition occurs. The transition energy is found to be highly sensitive to the size of the rapidity bin, while it is only weakly dependent on the type of the rapidity distribution. These theoretical findings are found to be in agreement with experimental results.