demographic properties, life history pattern and response to exploitation. Ignoring underlying spatial stock structure in a fishery management system can increase risk of local depletion, resulting in loss of genetic diversity [1][2][3]. Therefore, a thorough understanding of stock structure is the starting point of effective management in multi-stock fisheries [4,5].Otolith shape is subjected to a combination of genetic and environment effects and demonstrates stock-specific features [6]. It has also been deemed to be an ideal natural marker for spatial stock, and is widely used in stock identification. The introduction of multiple image analysis techniques improves the ability to visualize and compare otolith shape, such as Fourier analysis [7,8], curvature scale space [9], wavelet transform [10, 11] and partial reflection [12]. However, few efforts have been put into the improvement of classification methods, whereas machine-learning methods (e.g. random forests, artificial neural networks) have been applied in fish parasites and otolith microchemistry, and have outperformed discriminant analysis [13][14][15]. Discriminant analysis (linear, quadratic and canonical) is commonly used in population studies based on otolith shape, and multivariate normality and independence of the predictor variables are required for this method. Appropriate data transformations (log, square root, etc.) are often required to reach a normal distribution. As to multi-collinearity, there are two options: a principle component analysis or excluding variables with significant multi-collinearity. Algorithmic advantages of random forests enable researchers to eliminate the above steps, maximize the number of variables inputted for discrimination and retain the original information of each variable. However, an increase in classification accuracy has its own limits with the variables used, and many variables increase intrinsic classification accuracy but also decrease extrinsic accuracy in Abstract In this study, the population structure of Japanese Spanish mackerel Scomberomorus niphonius were investigated based on the geographical variation of otolith features, and the concept of random forests was introduced as a classifier. Samples were collected from eight main spawning grounds using commercial gill nets, covering the distribution range along the coast of China. Otolith shape was described by the shape variables and principle components of Fourier coefficients. Every possible combination of otolith variable was tested to search for an optimal variable combination. An intermediate number of variables (8 out of 13) produced the most discriminating signal, and then the eight grounds were divided into three stocks with 64.5 % global accuracy. The discriminant result provided phenotypic evidence for the common migration trajectory, and further confirmed the existence of a metapopulation in Japanese Spanish mackerel at a larger scale.