i have long vecotr od srings,  dane[:,5]
saved by
is only ±33 000 KB
but saved by
@time  write(file,“user”,string.(dane[:,5]))
created file over 40 000 000 KB !!! What wrong ? How to optymaly this vector to save in JLD ? …as string.
             
            
              
            
           
          
            
              
                mauro3  
              
                  
                    September 24, 2017,  8:23am
                   
                  2 
               
             
            
              Try JLD2?  Also please quote code with   ` and blocks of code with ```.
             
            
              
            
           
          
            
            
              Also, if each element of that array
contains only ASCII characters, 
has uniform length, or variable length that can be bounded by a small number, 
 
then Matrix{UInt8} is also a viable choice.
If the strings repeat a lot, you could collect them and index into it. See for examplehttps://github.com/JuliaComputing/PooledArrays.jl 
             
            
              
            
           
          
            
            
              Yes, JLD2 make to lage file also!
             
            
              
            
           
          
            
            
              What happens if you convert the array to actually be of type Vector{String} instead of Vector{Any}?
             
            
              
            
           
          
            
            
              Thanks, convert(Array{String},a) with JLD working better!
BUT, if i Have vector “a” {Any} like below. In this case is npossible to make CONVERT(…
If i am using  string.(a) the saved data are huge:/
julia> a
julia> string.(a)
julia> convert(Array{String},a)convert an object of type Int64 to an object of type String
             
            
              
            
           
          
            
            
              I have !
             
            
              
            
           
          
            
            
              string.(a) doesn’t modify a, it returns a new array.
             
            
              1 Like