There is no widely recognized chemical classification of sedimentary rocks. The geochemical classification of sedimentary rocks utilizes features that can be observed in hand specimens or in thin sections, such as grain size and the mineralogy of the particles and matrix. The main objective behind this paper is to compare the performance of different pattern-recognition techniques, such as artificial neural networks, linear discriminant analysis, the k-nearest neighbour technique and "soft independent modelling of class analogy" in classifying Silurian sedimentary rocks from Lithuania. The comparison was made separately for major and trace elements. To obtain an idea about the success of the various classifiers in correctly predicting samples from each of the individual rock types, error rates were also computed for each of seven petrographically established rock types. For testing the predictive power of the artificial neural networks we applied a back propagation network. Error rates were computed based on the average percentage of misclassifications. The comparison of pattern-recognition techniques used in this study indicates that not only the technique for classification should be applied with care but also that attention must be paid to the objects (rock types) being classified. It was also noticed that not only the major elements, as is usually the case, could be used in "recognition" of certain rock types. Trace elements could also successfully be used and readily handle the same tasks. The results indicate that two techniques, artificial neural networks and linear discriminant analysis, yield the lowest error rates for both major and trace elements (7-8% for the major elements and 8-14% for the trace elements). The k-nearest neighbour technique and soft independent modelling of class analogy produce considerably higher error rates for both types of elements (16-25%). Since no strict statistical assumptions, for example, multivariate normality of a data set, are required in the artificial neural networks, this procedure seems to be the optimum technique for geochemical classification of the sedimentary rocks.