Chemical spectroscopy is an invaluable tool in commerce, public safety, health care, national security, and scientific research. In most cases a measurement expert with considerable experience using an ill-defined catalog of heuristic rules is required to optimize the instrument and to interpret the data. Using an expert is expensive, not always reproducible, and introduces uncontrolled bias to the measurement process. Numerical algorithms for nonlinear optimization can supplement, and perhaps even replace, the knowledge of the expert operator. I will discuss my work with one of the most complex and fastest growing of the new chemical spectroscopies: matrix assisted laser desorption/ionization time of flight mass spectrometry (MALDI TOF MS). This technique finds broad application in both the biological and materials sciences, from drug discovery to the development of high performance plastics. I will demonstrate the application of an optimization method applied to the analysis of a synthetic polymer, one of the most difficult species to analyze by MALDI TOF MS.