Hi,

This is to share my finding of using the Juila for Matlab users.

I have a few big size data in csv format to open from the Juila and it 
tooks at least 3 minutes to read. However, if I convert the file into 
Matlab format (.mat)  and load the file with Matlab, it tooks only one 
minute.

I searched the Julia and find the MAT package. 

https://github.com/simonster/MAT.jl

Instead of the csv file, I open the file with Matlab format data using the 
MAT package and it took only *a few second* !!!!!!

using MAT   

MN=@sprintf("MODEL_%02d.mat",2); # this code is to select the 2nd matlab file 
for me. 

              #check the name of the variable name you saved in Matlab first

 file = matopen(MN);  # you can type your file name directly from here like, 
"MODEL_02.mat"

 varnames = names(file);  #I found "*MODEL*" was the name of the varnames

 close(file)        


# Now call the variable from Julia        

 file = matopen(MN);

 MODEL=read(file, "*MODEL*"); # Enter the name of the varnames above at" " and 
assign variable name again!! 

 close(file)


# Now whether you open the righ file

  size(MODEL)



It's fantastic and this prove Julia has something more than other languages but 
still Julia is lack of tutorials to cover. I suggest to share this kind of your 
findings for the progress of the Julia and for the convenience of the users.


Thank you Julia.


Jase

     

Reply via email to