def moments_match_ep(self, data_i, tau_i, v_i, Y_metadata_i=None):
sigma2_hat = <NUM_LIT:1.>/(<NUM_LIT:1.>/self.variance + tau_i)<EOL>mu_hat = sigma2_hat*(data_i/self.variance + v_i)<EOL>sum_var = self.variance + <NUM_LIT:1.>/tau_i<EOL>Z_hat = <NUM_LIT:1.>/np.sqrt(<NUM_LIT>*np.pi*sum_var)*np.exp(-<NUM_LIT>*(data_i - v_i/tau_i)**<NUM_LIT>/sum_var)<EOL>return Z_hat, mu_hat, sigma2_hat<EOL>
Moments match of the marginal approximation in EP algorithm

:param i: number of observation (int)
:param tau_i: precision of the cavity distribution (float)
:param v_i: mean/variance of the cavity distribution (float)