I have zlib compressed strings (example is attached)
What is that file? Not gzip compression:
gannet% file compressed.txt
compressed.txt: ASCII text, with very long lines
since gzip uses a magic header that 'file' knows about. And even if
the header was stripped, such files are 8-bit and yours is ASCII.
Try
x <- 'Johannes Graumann'
xx <- charToRaw(x)
xxx <- memCompress(xx, "g")
rawToChar(xxx)
[1] "x\x9c\xf3\xca\xcfH\xcc\xcbK-Vp/J,\xcd\0052\001:\n\006\x90"
to see what a real gzipped string looks like.
and would like to decompress them using memDecompress ...
I try this:
connection <- file("compressed.txt","r")
compressed <- readLines(connection)