The workspace can be saved to file when closing an R or RStudio session. It contains all of the objects in your namespace when the previous session was close if save workspace is set as the default element or chosen as the option on exit manually.
You do not need the workspace to run an R script unless the script depends on objects created outside the script and not saved to file. For example
some_function(some_object) -> some_other_object
To debug, try navigating to the location with your R script and
which will perform whatever operations it performs and complain about missing objects it expects or, if so specified, read data from file and transform it into the objects it needs.