Stroke, as one of Global Burden Disease (GBD), obstructing the flow of blood to the brain and neurologic devastation, comprises of two types, namely hemorrhagic and ischemic with approximately 87% of all strokes classified as ischemic due to cerebral infarction or the occlusion of a cerebral vessel. Therefore, early identification is needed to enable patients to obtain the right treatment and prevent chronic cerebral infarction. This research proposes the use of a machine learning algorithm for appropriate and early diagnosis of patients with cerebral infarction by comparing linear function kernel of Support Vector Machine (SVM) and logistic regression methods. The main advantage of this method is its ability to determine the best linear classifier between these two methods for cerebral infarction classification in four criteria, namely accuracy, precision, recall, and F1 score. The highest average accuracy and F1 score were used to determine the best classifier. The result showed that the linear function kernel of support vector machine is the best for cerebral infarction classification with 90.96% and 91.44% average of accuracy and F1 score, respectively. In conclusion, future studies need to be carried out to improve machine learning classification for medical diagnosis using a linear classifier.