Is the expectation of the minimum of a function equal to the minimum of the expectation? Given two random variables $X$ and $Y$ and a differentiable function let $f(Y|X=x)$ be a function of Y for fixed values of $X$. Furthermore let $$\tilde{Y} = \text{argmin}_Y \ [f(Y|X=x)]$$ so that $f(\tilde{Y}|X=x) = \text{min} \ f(Y|X=x)$. Denote the expectation of $f(Y|X)$ over $X$ as $$E_X[f(Y|X)]=\int_X f(Y|X)p(X)dX.$$ 
Is $$\text{min} \ E_X[f(Y|X)] =\int_X f(\tilde{Y}|X)p(X)dX, $$
that is, is the minimum of the expectation of $f$ across $X$ equal to the expectation of the pointwise minimized function? 
 A: Generally in statistics and random processes, uppercase variables represent random variables that assume no real value, while lower case variables are the possible outcomes of the respective random variable.
That being said, the conditional distribution function should be denoted by $f_Y(y|X=x)$, while the regular pdf would be denoted as $f_{XY}(x,y)$. So we can rewrite your first equation as:
$$
\tilde{y} = \text{argmin}_y f_Y(y|X=x)
$$
Such that: $\forall y$:
$$
f_Y(\tilde{y}|X=x) \leq f_Y(y|X=x)
$$
In this case your $\tilde{y}=\tilde{y}(x)$, since it depend on the given $x$. Also, in general, you cannot write $\text{min}f(Y|X)$ because the upper case letters denote random variables with no associated value, thus this function does not have entries to be optimized (unlike $f(x,y)$).
Now the conditional expectation of a different function $g(X,Y)$ is generally expressed as:
$$
E[g(X,Y)|X=x] = \int g(x,y)  f_Y(y|X=x) dy = h_1(x)
$$
Notice that this result is in principle not a function of $y$, but rather on the fixed $x$ which is the "given" value of $x$. 
For the conditional expectation given $y$ you would have:
$$
E[g(X,Y)|Y=y] = \int g(x,y)  f_X(x|Y=y) dx = h_2(y)
$$
Now let's assume that instead of a fixed $y$ the premise was $Y=\tilde{y}(x)$, then:
$$
E[g(X,Y)|Y=\tilde{y}(x)] = \int g(x,\tilde{y}(x))  f_X(x|Y=\tilde{y}(x)) dx = C
$$
So, if I'm managing to put your question in more rigorous terms, you mean to ask if:
$$
 C = \text{min}_y h_2(y)
$$
The answer is no. Pick $g(x,y)=(x-y)^2$ and any continuous distribution over an interval, then $C=0$ while $h_2(y)$ is always larger than zero.
