As Mr.Wizard already noted, it's not clear whether "operator form" occurs in the documentation of every command that has an operator form (or conversely, e.g., NDSolve*
, which references the operator form of Inactive
).
docdir = FileNameJoin[{$InstallationDirectory, "Documentation",
"English", "System", "ReferencePages", "Symbols"}];
docs = FileNames["*", docdir];
ops = Count[Get[#],
s_String /; StringMatchQ[s, ___ ~~ "operator form" ~~ ___],
Infinity] & /@ docs
ToExpression @ Pick[StringDrop[#, -3] & /@ FileNameTake /@ docs, Unitize[ops], 1]
(*
{AllTrue, AnyTrue, Append, Apply, AssociationMap, Cases, \
CellularAutomaton, CountDistinctBy, Count, CountsBy, Dataset, \
DeleteCases, DeleteDuplicatesBy, Delete, Extract, FirstCase, \
FirstPosition, FreeQ, GroupBy, Insert, KeyDrop, KeyExistsQ, KeyMap, \
KeySelect, KeySortBy, KeyTake, KeyValueMap, Lookup, MapAt, \
MapIndexed, Map, MatchQ, MaximalBy, MemberQ, Merge, MinimalBy, \
NDSolve, NDSolveValue, NoneTrue, Position, Prepend, Query, Replace, \
ReplacePart, Scan, SelectFirst, Select, SortBy, StringCases, \
StringContainsQ, StringDelete, StringEndsQ, StringStartsQ, \
TakeLargestBy, TakeLargest, TakeSmallestBy, TakeSmallest}
*)
On a Unix system, you can do this:
commandstring = "!cd " <> docdir <> "; fgrep -l \"operator form\" *";
StringDrop[#, -3] & /@ Import[commandstring, "List"] // ToExpression
Map
do too. I do not know how to check a Symbol for such a syntax directly and I fear that the documentation is not consistent enough to use detection of the phrase "operator form" for robust determination. $\endgroup$SyntaxInformation
onNames["System`*"]
and then check which of the function that allow a single-argument spec return unevaluated (i.e. in an operator form) without a message when given a single argument, likeMap[#&]
does now. $\endgroup$