Consider the following test. It randomly samples from a bunch of symbols, builds a matrix, writecsv
s it, readcsv
s it, and then compares the two. It fails with even really small n
s.
function genmat(collection, n)
#randomly collects `n` charachters from String `collection` and fills a 3x2 matrix, saves this matrix to csv file, reads the text of this saved file, and returns both matrices
c = [i for i in collection]
x = [join(rand(c, n)) for i = 1:3, j = 1:2]
writecsv("a.csv", x, quotes = true)
y = readcsv("a.csv", String, quotes = true)
return (x, y)
end
collection = """!#¤%"&/()=?*_:;><,.-'§½`'äöåÄÖÅ\\\n\t\b """
n = 1000
x, y = genmat(collection, n)
@assert x == y # this fails with high probabilities even for a really small `n`
maybe this is related.