Statistical Inference for Probabilistic Functions of Finite State Markov Chains