This paper describes the prediction of the accidents and incidents by modelling the faults that are hard to be predicted, and forms the stochastic processes in railways. As it is seen, the root causes of the occurrence of the accidents and incidents in railways are the technical faults, the organizational faults, the staff faults, the third-party faults, the other faults and some parameters affecting these faults holidays, seasonal effects etc. The system model was set up by considering the above-mentioned faults and the causes as the inputs of the model and the accidents and the incidents as the outputs of the model. The real values of the accidents and the incidents were compared with the predicted values by using Artificial Neural Networks-ANN and Support Vector Machines-SVM. The results, which were acquired by this article, are considered as a guide because of the absence of any studies about the prediction of the accidents caused by the faults.