Tracking pylorus in ultrasonic image sequences is an important step in the analysis of duodenogastric reflux (DGR). We propose a joint prediction and segmentation method (JPS) which combines optical flow with active contour to track pylorus. The goal of the proposed method is to improve the pyloric tracking accuracy by taking account of not only the connection information among edge points but also the spatio-temporal information among consecutive frames. The proposed method is compared with other four tracking methods by using both synthetic and real ultrasonic image sequences. Several numerical indexes: Hausdorff distance (HD), average distance (AD), mean edge distance (MED), and edge curvature (EC) have been calculated to evaluate the performance of each method. JPS achieves the minimum distance metrics (HD, AD, and MED) and a smaller EC. The experimental results indicate that JPS gives a better tracking performance than others by the best agreement with the gold curves while keeping the smoothness of the result.