Will now calculate chi-squared using luminosity rather than  temperature if needed