Choose starting values for all global shrinkage parameters $({a}^{\tau},{c}^{\tau},{\lambda}_{B}^{2},{a}^{\xi},{c}^{\xi},{\kappa}_{B}^{2})$ and local shrinkage parameters ${\{{\stackrel{\u02c7}{\tau}}_{j}^{2},{\stackrel{\u02c7}{\lambda}}_{j}^{2},{\stackrel{\u02c7}{\xi}}_{j}^{2},{\stackrel{\u02c7}{\kappa}}_{j}^{2}\}}_{j=1}^{d}$, and repeat the following steps: (a)
Define for $j=1,\dots ,d$, ${\tau}_{j}^{2}={\varphi}^{\tau}{\stackrel{\u02c7}{\tau}}_{j}^{2}/{\stackrel{\u02c7}{\lambda}}_{j}^{2}$ and ${\xi}_{j}^{2}={\varphi}^{\xi}{\stackrel{\u02c7}{\xi}}_{j}^{2}/{\stackrel{\u02c7}{\kappa}}_{j}^{2}$ and sample from the posterior $p({\tilde{\mathit{\beta}}}_{0},\dots ,{\tilde{\mathit{\beta}}}_{T},{\beta}_{1},\dots ,{\beta}_{d},\sqrt{{\theta}_{1}},\dots ,\sqrt{{\theta}_{d}}{\{{\xi}_{j}^{2},{\tau}_{j}^{2}\}}_{j=1}^{d},\mathit{y})$ using Algorithm 1, Steps (a), (b), and (c) in Bitto and FrühwirthSchnatter (2019). In the homoscedastic case, use Step (f) of this algorithm to sample from ${\sigma}^{2}{\mathit{z}}_{{\sigma}^{2}},\mathit{y}$. For the SV model (2), sample the parameters μ, ϕ, and ${\sigma}_{\eta}^{2}$ as in Kastner and FrühwirthSchnatter (2014), for example, using the Rpackagestochvol(Kastner 2016).  (b)
Use the prior $p({\sqrt{\theta}}_{j}{\stackrel{\u02c7}{\kappa}}_{j}^{2},{a}^{\xi},{c}^{\xi})$, marginalized w.r.t. ${\stackrel{\u02c7}{\xi}}_{j}^{2}$, to sample ${a}^{\xi}$ from $p({a}^{\xi}{\mathit{z}}_{{a}^{\xi}},\mathit{y})$ via a random walk MH step on $z=log({a}^{\xi}/(0.5{a}^{\xi}))$. Propose ${a}^{\xi ,(*)}=0.5{e}^{{z}^{*}}/(1+{e}^{{z}^{*}})$, where ${z}^{*}\sim \mathcal{N}\left({z}^{(m1)},{v}^{2}\right)$ and ${z}^{(m1)}=log({a}^{\xi ,(m1)}/(0.5{a}^{\xi ,(m1)}))$ depends on the previous value ${a}^{\xi ,(m1)}$ of ${a}^{\xi}$, accept ${a}^{\xi ,(*)}$ with probabilityand update ${\varphi}^{\xi}=2{c}^{\xi}/\left({\kappa}_{B}^{2}{a}^{\xi}\right)$. Explicit forms for $p({a}^{\xi}{\mathit{z}}_{{a}^{\xi}},\mathit{y})$ and $log{q}_{a}\left({a}^{\xi}\right)$ are provided in (A3) and (A4). Similarly, use the prior $p({\beta}_{j}{\stackrel{\u02c7}{\lambda}}_{j}^{2},{a}^{\tau},{c}^{\tau})$, marginalized w.r.t. to ${\stackrel{\u02c7}{\tau}}_{j}^{2}$, to sample ${a}^{\tau}$ via a random walk MH step and update ${\varphi}^{\tau}=2{c}^{\tau}/\left({a}^{\tau}{\lambda}_{B}^{2}\right)$.  (c)
Sample ${\stackrel{\u02c7}{\xi}}_{j}^{2}$, $j=1,\dots ,d$, from a generalized inverse Gaussian distribution, see (A5): Similarly, update ${\stackrel{\u02c7}{\tau}}_{j}^{2}$, $j=1,\dots ,d$, conditional on ${a}^{\tau}$:  (d)
Use the marginal Studentt distribution $p({\sqrt{\theta}}_{j}{\stackrel{\u02c7}{\xi}}_{j}^{2},{c}^{\xi},{\kappa}_{B}^{2})$ given in (11) to sample ${c}^{\xi}$ from $p({c}^{\xi}{\mathit{z}}_{{c}^{\xi}},\mathit{y})$ via a random walk MH step on $z=log({c}^{\xi}/(0.5{c}^{\xi}))$. Propose ${c}^{\xi ,(*)}=0.5{\mathrm{e}}^{{z}^{*}}/(1+{\mathrm{e}}^{{z}^{*}})$, where ${z}^{*}\sim \mathcal{N}\left({z}^{(m1)},{v}^{2}\right)$ and ${z}^{(m1)}=log({c}^{\xi ,(m1)}/(0.5{c}^{\xi ,(m1)}))$ depends on the previous value ${c}^{\xi ,(m1)}$ of ${c}^{\xi}$, accept ${c}^{\xi ,(*)}$ with probabilityand update ${\varphi}^{\xi}=2{c}^{\xi}/\left({\kappa}_{B}^{2}{a}^{\xi}\right)$. Explicit forms for $p({c}^{\xi}{\mathit{z}}_{{c}^{\xi}},\mathit{y})$ and $log{q}_{c}\left({c}^{\xi}\right)$ are provided in (A6) and (A7). Similarly, to sample ${c}^{\tau}$ via a random walk MH step use the marginal distribution of ${\beta}_{j}{\stackrel{\u02c7}{\tau}}_{j}^{2},{a}^{\tau},{c}^{\tau}$ with respect to ${\stackrel{\u02c7}{\lambda}}_{j}^{2}$ and update ${\varphi}^{\tau}=2{c}^{\tau}/\left({a}^{\tau}{\lambda}_{B}^{2}\right)$.  (e)
Sample ${\stackrel{\u02c7}{\kappa}}_{j}^{2}$, for $j=1,\dots ,d$, from following gamma distribution, see (A8): Similarly, update ${\stackrel{\u02c7}{\lambda}}_{j}^{2}$, $j=1,\dots ,d$, conditional on ${c}^{\tau}$:  (f)
Sample ${d}_{2}$ from ${d}_{2}{a}^{\xi},{c}^{\xi},{\kappa}_{B}^{2}\sim \mathcal{G}\left({a}^{\xi}+{c}^{\xi},{\kappa}_{B}^{2}+\frac{2{c}^{\xi}}{{a}^{\xi}}\right)$, see (A9); sample from ${\kappa}_{B}^{2}$ from following gamma distribution,see (A10), and update ${\varphi}^{\xi}=2{c}^{\xi}/\left({\kappa}_{B}^{2}{a}^{\xi}\right)$. Similarly, sample ${e}_{2}$ from ${e}_{2}{a}^{\tau},{c}^{\tau},{\lambda}_{B}^{2}\sim \mathcal{G}\left({a}^{\tau}+{c}^{\tau},{\lambda}_{B}^{2}+\frac{2{c}^{\tau}}{{a}^{\tau}}\right)$, sample ${\lambda}_{B}^{2}$ fromand update ${\varphi}^{\tau}=2{c}^{\tau}/\left({a}^{\tau}{\lambda}_{B}^{2}\right)$.
