Joint distribution from conditional So the question is:
Let $\theta\sim U(0,1)$ and $X\mid\theta\sim\text{Binomial}(2,\theta)$. 
Find the joint distribution of $(X,\theta) $
The way the lecturer started was the following:
$$ P(X=k, \theta <t)= \int_0^t P(X=x\mid\theta=s) f_{\theta}(s) \, ds=\int_0^t {2 \choose k}s^k (1-s)^{(2-k)} \, ds .$$
Then you can find the distribution depending on $k=0,1,2$.
But I don't understand why do we integrate the conditional probability times $f_{\theta}(s)$ which is just $1$ so we are left with the integral of binomial only. And even why with respect to $s$ (probability)... Really confused about this.
Would be great if somebody could explain it . Thanks in advance.
 A: This can be explained by first principles. Forget for a moment the particular distributions of $X$ and $\Theta$ and suppose that both $X$ and $\Theta$ are discrete random variables, where $\Theta$ takes non-negative values.
What we seek is the probability $P(\{X=k,\Theta \le t\})= P(\{X=k,\Theta=0\} \cup \{X=k,\Theta=1\}\cup \dots \cup\{X=k,\Theta=t\}) = \sum_{s=0}^t P(X=k,\Theta=s)$
where the first equality is simply an expansion of the event of interest, and second equality follows from the fact that each of the events is disjoint.
Using the multiplication rule, this sum can be re-expressed as $\sum_{s=0}^{t} P(\Theta=s)P(X=k\mid\Theta=s)$.
Now, the problem you have posed has $\Theta$ as a continuous random variable, so (for intuitive, non-rigorous purposes) the discrete sum becomes an integral, and the probability $P(\Theta=s)$ becomes the probability of a small interval  $dsf_\Theta(s)$. This is the limiting process from which we can intuitively arrive at the result you are asking about:
$$\sum_{s=0}^t P(\Theta=s)P(X=k\mid\Theta=s) \rightarrow \int_0^t ds \, f_\Theta(s) P(X=t \mid \Theta=s)$$
Non-Limiting Argument
The result can also be derived from a direct application of the law of total probability (perhaps another "easy answer"), without limiting arguments
$P\{X=k,\Theta \le t\} \\ 
= \int_{-\infty}^{\infty}dsf_\Theta(s)P\{X=k,\Theta \le t \mid \Theta =s\} \\
= \int_{0}^{1}dsf_\Theta(s)P\{X=k,\Theta \le t \mid \Theta =s\} \\
= \int_{0}^{t}dsf_\Theta(s)P\{X=k,\Theta \le t \mid \Theta =s\} + \int_{t}^{1}dsf_\Theta(s)P\{X=k,\Theta \le t \mid \Theta =s\}
$
Now, the second integral in the summation is zero, since for all $s >t$ we have in the conditional universe $P(X=k,\Theta \le t \mid \Theta =s ) = 0$.
As for the first integral in the summation, it is easy to derive that, for all $s \in [0,t]$ we have $P(X=k,\Theta \le t \mid \Theta =s ) = P(X=k \mid \Theta =s )$. Making the appropriate substitution, we arrive at the result
$P(X=k,\Theta \le t) = \int_{0}^{t}dsf_\Theta(s)P\{X=k \mid \Theta =s\}$
