I understand that among the ways we can define macros, there are at least three main streams.
The original TeX method: We use the \def command (and similar ones)
to define macros. One very attractive feature is being able to
customize the argument parsing. When we write
\def\mymacro#1.#2-(#3){<macro definition>} we understand that the
first argument must be followed by a dot, the second one by a dash,
while the third argument must be enclosed between parentheses.
In this method, is it possible to declare an argument to be optional in a straightforward manner?
The LaTeX method: We use \newcommand (and \renewcommand) to define
(and redefine) macros. Optional argument declaration is
possible,
but I don't call it straightforward.
What if there more than one optional arguments? What about several optional arguments scattered among the mandatory arguments? Is it possible to control parsing of the arguments?
Necessitating the use of \renewcommand preventing accidental redefinition
of existing ones is a good feature.
\NewDocumentCommand using
xparse:
Looks like the latest one. The straightforward manner in which I can mix
the mandatory and optional arguments is particularly attractive to me.
Comes with other loads of features.
I am making this post asking those with really vast experience to tutor us on the relative merits and demerits of the three main streams. If want to stick to only one, which one should we choose? Or do we keep on using them all in the same document and use the one which fits my need of the moment?
(Though there are several sentences ending with question marks in this post, it is not a post with several questions. Rather, these are the talking points which the answerer will find to be helpful when creating the tutorial.)



(x,y)for coordinates). The more arguments a macro has, the harder is to remember their order and their delimiter. – egreg Aug 10 '17 at 10:06