Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have my Matlab folder at a path, C:\Users\Cassie\Documents\matlab2010\bin. Whenever I need to run matlab, I double click the matlab application under bin folder at

C:\Users\Cassie\Documents\matlab2010\bin\matlab    

In addition, most of time, I put all my programs inside this folder. I downloaded libsvm-3.12 to my window 7 pc. However, I have a hard to build the matlab interface. Here are my questions.

(1) Where should I put my libsvm-3.12 extracted folder ? Should I put it under bin folder or under my matlab2010 folder?

(2) I also downloaded Visual Studio C++ 2010 express and made my matlab to choose it as default C++ compiler. Then, I put the libsvm folder at toolbox folder as

C:\Users\Cassie\Documents\matlab2010\toolbox\libsvm-3.12\libsvm-3.12\matlab

I added the searching path in matlab by

addpath('C:\Users\Cassie\Documents\matlab2010\toolbox\libsvm-3.12\libsvm-3.12\matlab\');    

After I run "make" command, it gave me error message as

 C:\USERS\CASSIE\DOCUME~1\MATLAB~4\BIN\MEX.PL: Error: 'libsvmread.c' not found.    

However, the libsvmread.c does exist at matlab folder at

C:\Users\Cassie\Documents\matlab2010\toolbox\libsvm-3.12\libsvm-3.12\matlab\

I do not understand why matlab can not find the libsvmread.c file. Any one experiences the similar thing before ? How can I fix this problem ? Thank you very much,

share|improve this question
add comment

2 Answers

i had the same error of '...\BIN\MEX.PL: Error: 'libsvmread.c' not found.'

I navigated to the '...\libsvm-3.12\matlab' directory, in Matlab, and I was able to compile it.

(double-click in the 'Current Folder' window until you are inside the '...\libsvm-3.12\matlab' folder, or type the folder name into the 'Current Folder' bar at the top of Matlab.

Edit: FYI I was using Matlab 2012a

share|improve this answer
add comment
up vote 0 down vote accepted

I finally understand how to use libsvm matlab ROC tool on my pc. Here is the information of my pc:

(1) Window 7
(2) Matlab 2008a and Matlab2010

Resolution summery:
(1) Extract libsvm-3.12 package to anywhere you like.
(2) If you use window as I, skip the "make" command. Just copy everything under libsvm-3.12/libsvm-3.12/windows to your directory of Matlab. Ex, my matlab is at

C:\Users\Cassie\Documents\matlab2010\bin

Put everything there.
(3) Directly use them via your matlab prompt such as

>> [a,b] = libsvmread('heart-scale');

I shouldn't have to execute "make" or "mex -setup" at all. In addition, I need to put all files from libsvm-3.12/windows to my matlab folder directly. I hope some newbie as I can also benefit from my experience.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.