Yoshiko Ogata and Luc Rey-Bellet Ruelle-Lanford functions for quantum spin systems (324K, PDF) ABSTRACT. We prove a large deviation principle for the expectation of macroscopic observables in quantum (and classical) Gibbs states. Our proof is based on Ruelle-Lanford functions and direct subadditivity arguments, as in the classical case, instead of relying on G\"artner-Ellis theorem, and cluster expansion or transfer operators as done in the quantum case. In this approach we recover, expand, and unify quantum (and classical) large deviation results for lattice Gibbs states. In a companion paper we discuss the characterization of rate functions in terms of relative entropies.