refactor so that the spectra curves are dependent on poe, periods and investigation time from metadata source rather than columns in the db