finally got text file working, filereader does not recognise ~ as home directory