문제

When creating a libsvm training file, how do you differentiate between a nominal attribute verses a numeric attribute? I'm trying to encode certain nominal attributes as integers, but I want to ensure libsvm doesn't misinterpret them as numeric values. Unfortunately, libsvm's site seems to have very little documentation. Pentaho's docs seem to imply libsvm makes this distinction, but I'm still not clear how it's made.

도움이 되었습니까?

해결책

Don't do this I'm trying to encode certain nominal attributes as integers.

Rather, use a separate binary feature for each value of each nominal attribute.

The way SVMs are formulated, all attributes/features are numeric and class labels are nominal. Nominal attributes are essentially faked by using mutually exclusive binary features.

다른 팁

I think you cant do that in libsvm, weka or SVM-light. One approach that you could use is to use something like a decision tree for your nominal attributes and svm or any distance based classifier for your numeric attributes and then combine the results. I hope it helps.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top