The equilibrium inorganic aerosol model ISORROPIA was embedded in a Markov Chain Monte Carlo algorithm to develop a powerful tool to analyze aerosol data and predict gas phase concentrations where these are unavailable. The method directly incorporates measurement uncertainty, prior knowledge, and provides a formal framework to combine measurements of different quality. The method was applied to particle- and gas-phase precursor observations taken at La Merced during the Mexico City Metropolitan Area (MCMA) 2003 Field Campaign and served to discriminate between diverging gas-phase observations of ammonia and predict gas-phase concentrations of hydrochloric acid. The model reproduced observations of particle-phase ammonium, nitrate, and sulfate well. The most likely concentrations of ammonia were found to vary between 4 and 26 ppbv, while the range for nitric acid was 0.1 to 55 ppbv. During periods where the aerosol chloride observations were consistently above the detection limit, the model was able to reproduce the aerosol chloride observations well and predicted the most likely gas-phase hydrochloric acid concentration varied between 0.4 and 5 ppbv. Despite the high ammonia concentrations observed and predicted by the model, when the aerosols were assumed to be in the efflorescence branch they are predicted to be acidic (pH~3).