I would like to be able to have a defined macro something like this:
\def\testmacro[1]{[54.7],[74.1],[98.5]}
Such that when I call
\testmacro{2},
in a document,
74.1
is printed. Is this possible?
Background:
I'm writing a C++ program that will export data to a TeX file. I have up to twenty items (but sometimes fewer), which have various measurement, like pressure. This TeX file will call for a template, which will specify how different data is actually printed. In the template, I will specify that I want to print pressure for the second item here.
I'd love to be able to say:
\def\pressure1{54.7}
\def\pressure2{74.1}
etc, but Tex can't handle numbers in macro names. Any suggestions?
Thanks, Ben

