There are three overloads that use a function pointer that can be used for manipulators. Three signatures:
std::ios_base& (*)(std::ios_base&)
std::basic_ios<cT, Traits>& (*)(std::basic_ios<cT, Traits>&);
std::basic_ostream<cT, Traits>& (*)(std::basic_ostream<cT, Traits>&);
Signature you signed ( std::ios_base&(*)(std::basic_ios<cT, Traits>&)) is not anything.
I assume that you are using the actual settings as examples, because the manipulator std::scientificalready implements the logic that the sample code is trying to implement.