pr/3773 

Here are a couple of tweaks to your scipy PR, mainly adding an option for string keywords along with numerical values, as suggested by Ralf in scipy issue 3350. Can you have a look at the changes, and if they make sense to you, just accept the PR --- my two commits should automatically propagate to the scipy PR.