Re: [Rcpp-devel] R.e. Using Rcpp and MATLAB MAT-File API to Read MAT Files

2015-03-25 Thread Elliot Joel Bernstein
John - One quick follow-up about the warnings: I think they have to do with loading cell arrays. Basically, all the actual data ends up in the #refs# field, in what seems like an arbitrary order, and the field that should contain the data is all NAs. Do you know if there's any way to get around th

Re: [Rcpp-devel] R.e. Using Rcpp and MATLAB MAT-File API to Read MAT Files

2015-03-25 Thread Elliot Joel Bernstein
John - Thanks for the suggestions. I tried taking not only Rcpp but R out of the loop, and just compiling from the command line with MinGW. That crashed as well, so I think there's probably a compatibility issue with MATLAB's API and MinGW. I'll contact Mathworks tech support to try and get some h

Re: [Rcpp-devel] R.e. Using Rcpp and MATLAB MAT-File API to Read MAT Files

2015-03-25 Thread John Buonagurio
Elliot, How are you building the executable? Did you make sure to include all dependencies in the search path (run depends.exe against libmat.dll and libmx.dll)? Did you make sure to set the appropriate architecture e.g. -m64 in CFLAGS? I don't have access to the MAT-File libraries to test this

Re: [Rcpp-devel] R.e. Using Rcpp and MATLAB MAT-File API to Read MAT Files

2015-03-25 Thread Elliot Joel Bernstein
Dale - Thank you for the suggestion. I have MATLAB and the MATLAB libraries, and I am not looking to redistribute anything. I just have a lot of data in MAT files that I would like to be able to load analyze in R. I am able to compile and link against the MATLAB libraries, but the code crashes whe

Re: [Rcpp-devel] R.e. Using Rcpp and MATLAB MAT-File API to Read MAT Files

2015-03-25 Thread Dale Smith
mat.h is a header file which comes with MATLAB. I don't think the license allows redistribution, and you would not be able to compile without the MATLAB libraries. An alternative may be Octave since it will read .mat files. Perhaps someone can email the name of the header file used from the Oct

[Rcpp-devel] R.e. Using Rcpp and MATLAB MAT-File API to Read MAT Files

2015-03-25 Thread Christian Gunning
Can you provide a link to the mat.h file referenced in the source (which I assume is the same as the API mentioned below)? Also, see Dirk's comments about compilers here: http://stackoverflow.com/questions/10723165/using-visual-c-with-r and here: dirk.eddelbuettel.com/code/rcpp/Rcpp-FAQ.pdf Best,