I am performing machine learning using SVM on sentiment analysis. I have imbalance in my dataset with class 1 having 5 times samples than class 0. I read that there are few things that we can do: (1) I cannot perform the undersampling as I have limited dataset (2) I performed oversampling using SMOTE and Random over sampling from imblearn.over_sampling. I am getting accuracy of 0.5, AUC of 0.5 and f-score keeps changing everytime I run the code (On the trainig data only, on testing f-score is just 0.006). This is behavior of random classifier, I think. (3) Using the class weight 5 times for class 0 than class 1 still gives the same result.

Now, I used the same feature earlier and got f-score of 0.67 and AUC of 0.73 which was good for me. I have just increased vocabulary and I am getting this result.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.