Stochastic approximation Monte Carlo importance sampling for approximating exact conditional probabilities