2.5 When to use file.choose()
Instead of specifying a file path and name in one of the read
functions, there is an option to include file.choose()
. When the code is run, you are prompted to browse to a file and select it. I do not recommend this method as it is not reproducible. You will have no record of which file you actually chose. However, if you are creating an interactive application, then file.choose()
is what you need to allow the user to select their file.