You could use the below macro to do this. It creates a list of macro variables from the variable doctor and loops through the PROC EXPORT statements. The value of doctor is resolved in both the WHERE= data set option as well as the OUTFILE=option.
You might also want to take a look at the ExcelXP tagset which allows you to generate multiple worksheets based on the by value as well. See the below for more information on this.