I want to create a log file which should have info, errors, warnings, commands just like similar to RStduio console. save that in a text file.
I've tried savehistory(), sink(), Rcmd() function. but none of them are working since I'm running the R codes in non Rgui environment. is there any other possibilities to do that.
sink()does not take all of those arguments. I got output running this code.