Export an array to a CSV file in Julia Export an array to a CSV file in Julia arrays arrays

Export an array to a CSV file in Julia


You need to load DelimitedFiles module and now only writedlm function is supported.

So in order to write an array as CSV file use:

julia> using DelimitedFilesjulia> writedlm( "FileName.csv",  A, ',')

To get the same result with CSV.jl package use:

julia> using CSV, Tablesjulia> CSV.write("FileName.csv",  Tables.table(A), writeheader=false)

as Matrix does not support Tables.jl interface so you need to wrap it with Tables.table.