### 统计代写|机器学习代写machine learning代考|The Relevance Vector Machine

statistics-lab™ 为您的留学生涯保驾护航 在代写机器学习machine learning方面已经树立了自己的口碑, 保证靠谱, 高质且原创的统计Statistics代写服务。我们的专家在代写机器学习machine learning代写方面经验极为丰富，各种代写机器学习machine learning相关的作业也就用不着说。

• Statistical Inference 统计推断
• Statistical Computing 统计计算
• (Generalized) Linear Models 广义线性模型
• Statistical Machine Learning 统计机器学习
• Longitudinal Data Analysis 纵向数据分析
• Foundations of Data Science 数据科学基础

## 统计代写|机器学习代写machine learning代考|The Relevance Vector Machine

In the last section we saw that a direct application of Bayesian ideas to the problem of regression estimation yields efficient algorithms known as Gaussian processes. In this section we will carry out the same analysis with a slightly refined prior $\mathbf{P}{\mathrm{w}}$ on linear functions $f{\mathrm{w}}$ in terms of their weight vectors $\mathbf{w} \in \mathcal{K} \subseteq \ell_{2}^{n}$. As we will

see in Section $5.2$ an important quantity in the study of the generalization error is the sparsity $|\mathbf{w}|_{0}=\sum_{i=1}^{n} \mathbf{I}{w{i} \neq 0}$ or $|\boldsymbol{\alpha}|_{0}$ of the weight vector or the vector of expansion coefficients, respectively. In particular, it is shown that the expected risk of the classifier $f_{\mathrm{w}}$ learned from a training sample $z \in \mathcal{Z}^{m}$ is, with high probability over the random draw of $z$, as small as $\approx \frac{\boldsymbol{w}{0}}{n}$ or $\frac{|\alpha|{0}}{m}$, where $n$ is the dimensionality of the feature space $\mathcal{K}$ and $\mathbf{w}=\sum_{i=1}^{m} \alpha_{i} \mathbf{x}{i}=\mathbf{X}^{\prime} \alpha$. These results suggest favoring weight vectors with a small number of non-zero coefficients. One way to achieve this is to modify the prior in equation (3.8), giving $\mathbf{P}{\mathbf{W}}=\operatorname{Normal}(\mathbf{0}, \boldsymbol{\Theta})$,
where $\boldsymbol{\Theta}=\operatorname{diag}(\theta)$ and $\theta=\left(\theta_{1}, \ldots, \theta_{n}\right)^{\prime} \in\left(\mathbb{R}^{+}\right)^{n}$ is assumed known. The idea behind this prior is similar to the idea of automatic relevance determination given in Example 3.12. By considering $\theta_{i} \rightarrow 0$ we see that the only possible value for the $i$ th component of the weight vector $w$ is 0 and, therefore, even when considering the Bayesian prediction $B a y e s_{z}$ the $i$ th component is set to zero. In order to make inference we consider the likelihood model given in equation (3.9), that is, we assume that the target values $t=\left(t_{1}, \ldots, t_{m}\right) \in \mathbb{R}^{m}$ are normally distributed with mean $\left\langle\mathbf{x}{i}, \mathbf{w}\right\rangle$ and variance $\sigma{t}^{2}$. Using Theorem A.28 it follows that the posterior measure over weight vectors $\mathbf{w}$ is again Gaussian, i.e.,
$\mathbf{P}{W \mid} \mathrm{X}^{m}=x, \mathrm{~T}^{\mathrm{m}}=t=\operatorname{Normal}(\boldsymbol{\mu}, \boldsymbol{\Sigma})$ where the posterior covariance $\mathbf{\Sigma} \in \mathbb{R}^{n \times n}$ and mean $\mu \in \mathbb{R}^{n}$ are given by $$\boldsymbol{\Sigma}=\left(\sigma{t}^{-2} \mathbf{X}^{\prime} \mathbf{X}+\boldsymbol{\Theta}^{-1}\right)^{-1}, \quad \boldsymbol{\mu}=\sigma_{t}^{-2} \boldsymbol{\Sigma} \mathbf{X}^{\prime} \boldsymbol{t}=\left(\mathbf{X}^{\prime} \mathbf{X}+\sigma_{t}^{2} \mathbf{\Theta}^{-1}\right)^{-1} \mathbf{X}^{\prime} \boldsymbol{t}$$
As described in the last section, the Bayesian prediction at a new test object $x \in \mathcal{X}$ is given by $B a$ ayes $_{z}(x)=\langle\mathbf{x}, \boldsymbol{\mu}\rangle$. Since we assumed that many of the $\theta_{i}$ are zero, i.e., the effective number $n_{\text {eff }}=|\theta|_{0}$ of features $\phi_{i}: \mathcal{X} \rightarrow \mathbb{R}$ is small, it follows that $\boldsymbol{\Sigma}$ and $\boldsymbol{\mu}$ are easy to calculate ${ }^{7}$. The interesting question is: Given a training sample $z=(\boldsymbol{x}, \boldsymbol{t}) \in(\mathcal{X} \times \mathbb{R})^{m}$, how can we “learn” the sparse vector $\boldsymbol{\theta}=\left(\theta_{1}, \ldots, \theta_{n}\right)^{\prime} ?$

## 统计代写|机器学习代写machine learning代考|Bayes Point Machines

The algorithms introduced in the last two sections solve the classification learning problem by taking a “detour” via the regression estimation problem. For each training object it is assumed that we have prior knowledge $\mathbf{P}{\mathbf{w}}$ about the latent variables $\mathrm{T}{i}$ corresponding to the logit transformation of the probability of $x_{i}$ being from the observed class $y_{i}$. This is a quite cumbersome assumption as we are unable to directly express prior knowledge on observed quantities such as the classes $\boldsymbol{y} \in \mathcal{Y}^{m}={-1,+1}^{m}$. In this section we are going to consider an algorithm which results from a direct modeling of the classes.

Let us start by defining the prior $\mathbf{P}{\mathbf{W}}$. In the classification case we note that, for any $\lambda>0$, the weight vectors $w$ and $\lambda w$ perform the same classification because $\operatorname{sign}(\langle\mathbf{x}, \mathbf{w}\rangle)=\operatorname{sign}(\langle\mathbf{x}, \lambda \mathbf{w}\rangle)$. As a consequence we consider only weight vectors of unit length, i.e., w $\in \mathcal{W}, \mathcal{W}={\mathbf{w} \in \mathcal{K} \mid|\mathbf{w}|=1}$ (see also Section 2.1). In the absence of any prior knowledge we assume a uniform prior measure $\mathbf{P}{\mathbf{W}}$ over the unit hypersphere $\mathcal{W}$. An argument in favor of the uniform prior is that the belief in the weight vector $w$ should be equal to the belief in the weight vector $-\mathbf{w}$

under the assumption of equal class probabilities $\mathbf{P}{\curlyvee}(-1)$ and $\mathbf{P}{\curlyvee}(+1)$. Since the classification $\mathbf{y}{-\mathbf{w}}=\left(\operatorname{sign}\left(\left\langle\mathbf{x}{1},-\mathbf{w}\right\rangle\right), \ldots, \operatorname{sign}\left(\left\langle\mathbf{x}{m},-\mathbf{w}\right\rangle\right)\right)$ of the weight vector $-\mathbf{w}$ at the training sample $z \in \mathcal{Z}^{m}$ equals the negated classification $-\mathbf{y}{\mathbf{w}}=$ $-\left(\operatorname{sign}\left(\left\langle\mathbf{x}{1}, \mathbf{w}\right\rangle\right), \ldots, \operatorname{sign}\left(\left\langle\mathbf{x}{m}, \mathbf{w}\right\rangle\right)\right)$ of $\mathbf{w}$ it follows that the assumption of equal belief in $\mathbf{w}$ and $-\mathbf{w}$ corresponds to assuming that $\mathbf{P}{\mathbf{Y}}(-1)=\mathbf{P}{\mathbf{Y}}(+1)=\frac{1}{2}$.

In order to derive an appropriate likelihood model, let us assume that there is no noise on the classifications, that is, we shall use the PAC-likelihood $l_{\mathrm{PAC}}$ as given in Definition 3.3. Note that such a likelihood model corresponds to using the zeroone loss $I_{0-1}$ in the machine learning scenario (see equations $(2.10)$ and $(3.2)$ ). According to Bayes’ theorem it follows that the posterior belief in weight vectors (and therefore in classifiers) is given by
\begin{aligned} f_{W \mid Z^{m}=z}(w) &=\frac{P_{Y^{m} \mid X^{m}=x, W=w}(y) f_{W}(w)}{P_{Y^{m} \mid X^{m}=x}(y)} \ &= \begin{cases}\frac{1}{P_{W}(V(z))} & \text { if } w \in V(z) \ 0 & \text { otherwise }\end{cases} \end{aligned}
The set $V(z) \subseteq \mathcal{W}$ is called version space and is the set of all weight vectors that parameterize classifiers which classify all the training objects correctly (see also Definition 2.12). Due to the PAC-likelihood, any weight vector which does not have this property is “cut-off” resulting in a uniform posterior measure $\mathbf{P}{\mathbf{W} \mid \mathbf{Z}^{m}=z}$ over version space. Given a new test object $x \in \mathcal{X}$ we can compute the predictive distribution $\mathbf{P}{Y \mid X=x, Z^{m}=z}$ of the class $y$ at $x \in \mathcal{X}$ by
$$\mathbf{P}{\mathrm{Y} \mid \mathrm{X}=x, Z^{w}=z}(y)=\mathbf{P}{\mathrm{W} \mid \mathbf{Z}^{m}=z}(\operatorname{sign}(\langle\mathbf{x}, \mathbf{W}\rangle)=y) .$$
The Bayes classification strategy based on $\mathbf{P}{\mathrm{Y} \mid \mathrm{X}=x, \mathrm{Z}^{\mathrm{m}}=z}$ decides on the class with the larger probability. An appealing feature of the two class case $\mathcal{Y}={-1,+1}$ is that this decision can also be written as $\operatorname{Bayes}{z}(x)=\operatorname{sign}\left(\mathbf{E}_{\mathbf{W} \mid \mathbf{Z}^{m}=z}[\operatorname{sign}(\langle\mathbf{x}, \mathbf{W}\rangle)]\right)$,
that is, the Bayes classification strategy effectively performs majority voting involving all version space classifiers. The difficulty with the latter expression is that we cannot analytically compute the expectation as this requires efficient integration of a convex body on a hypersphere (see also Figure $2.1$ and $2.8$ ). Hence, we approximate the Bayes classification strategy by a single classifier.

## 统计代写|机器学习代写machine learning代考|Estimating the Bayes Point

The main idea in computing the center of mass of version space is to replace the analytical integral by a sum over randomly drawn classifiers, i.e.,
$$\mathbf{w}{\mathrm{cm}}=\mathbf{E}{W \mid \mathbf{Z}^{\mathrm{w}}=z}[\mathbf{W}] \approx \frac{1}{K} \sum_{i=1}^{K} \mathbf{w}{i} \quad \mathbf{w}{i} \sim \mathbf{P}{\mathbf{W} \mid \mathbf{Z}^{m}=z}$$ Such methods are known as Monte-Carlo methods and have proven to be successful in practice. A difficulty we encounter with this approach is in obtaining samples $\mathbf{w}{i}$ drawn according to the distribution $\mathbf{P}{\mathbf{W} \mid \mathrm{Z}^{\mathrm{m}}=z \text {. Recalling }}$ that $\mathbf{P}{\mathrm{W} / \mathrm{Z}^{\mathrm{m}}=z}$ is uniform in a convex polyhedra on the surface of hypersphere in feature space we see that it is quite difficult to directly sample from it. A commonly used approach to this problem is to approximate the sampling distribution $\mathbf{P}{\mathrm{W} \mid \mathrm{Z}^{\mathrm{m}}=z}$ by a Markov chain. A Markov chain is fully specified by a probability distribution $\mathbf{P}{\mathrm{W}{1} \mathbf{W}{2}}$ where $f_{W_{1}} w_{2}\left(\left(w_{1}, w_{2}\right)\right)$ is the “transition” probability for progressing from a randomly drawn weight vector $\mathbf{w}{1}$ to another weight vector $\mathbf{w}{2}$. Sampling from the Markov chain involves iteratively drawing a new weight vector $w_{i+1}$ by sampling from $\mathbf{P}{\mathrm{W}{2} \mid \mathrm{W}{1}=\mathrm{w}{i} .}$ The Markov chain is called ergodic w.r.t. $\mathbf{P}{\mathbf{W} \mid \mathrm{Z}^{\mathrm{w}}=z}$ if the limiting distribution of this sampling process is $\mathbf{P}{\mathbf{w} \mid \mathbf{Z}^{m}=z}$ regardless of our choice of $\mathbf{w}{0}$. Then, it suffices to start with a random weight vector $w{0} \in \mathcal{W}$ and at each step, to obtain a new sample $\mathbf{w}{i} \in \mathcal{W}$ drawn according to $\mathbf{P}{\mathbf{w}{2} \mid \mathbf{w}{1}=\mathbf{w}{i-1} .}$. The combination of these two techniques has become known as the Markov-Chain-Monte-Carlo (MCMC) method for estimating the expectation $\mathbf{E}{\mathbf{W} \mid \mathbf{Z}^{w}=z}[\mathbf{W}]$.

We now outline an MCMC algorithm for approximating the Bayes point by the center of mass of version space $V(z)$ (the whole pseudo code is given on page 330). Since it is difficult to generate weight vectors that parameterize classifiers consistent with the whole training sample $z \in \mathcal{Z}^{m}$ we average over the trajectory of a ball which is placed inside version space and bounced like a billiard ball. As a consequence we call this MCMC method the kernel billiard. We express each position $\mathbf{b} \in \mathcal{W}$ of the ball and each estimate $\mathbf{w}{i} \in \mathcal{W}$ of the center of mass of $V(z)$ as a linear combination of the mapped training objects, i.e., $$\mathbf{w}=\sum{i=1}^{m} \alpha_{i} \mathbf{x}{i}, \quad \mathbf{b}=\sum{i=1}^{m} \gamma_{i} \mathbf{x}_{i}, \quad \alpha \in \mathbb{R}^{m}, \quad \boldsymbol{\gamma} \in \mathbb{R}^{m}$$

## 统计代写|机器学习代写machine learning代考|Bayes Point Machines

F在∣从米=和(在)=磷是米∣X米=X,在=在(是)F在(在)磷是米∣X米=X(是) ={1磷在(在(和)) 如果 在∈在(和) 0 除此以外

## 有限元方法代写

tatistics-lab作为专业的留学生服务机构，多年来已为美国、英国、加拿大、澳洲等留学热门地的学生提供专业的学术服务，包括但不限于Essay代写，Assignment代写，Dissertation代写，Report代写，小组作业代写，Proposal代写，Paper代写，Presentation代写，计算机作业代写，论文修改和润色，网课代做，exam代考等等。写作范围涵盖高中，本科，研究生等海外留学全阶段，辐射金融，经济学，会计学，审计学，管理学等全球99%专业科目。写作团队既有专业英语母语作者，也有海外名校硕博留学生，每位写作老师都拥有过硬的语言能力，专业的学科背景和学术写作经验。我们承诺100%原创，100%专业，100%准时，100%满意。

## MATLAB代写

MATLAB 是一种用于技术计算的高性能语言。它将计算、可视化和编程集成在一个易于使用的环境中，其中问题和解决方案以熟悉的数学符号表示。典型用途包括：数学和计算算法开发建模、仿真和原型制作数据分析、探索和可视化科学和工程图形应用程序开发，包括图形用户界面构建MATLAB 是一个交互式系统，其基本数据元素是一个不需要维度的数组。这使您可以解决许多技术计算问题，尤其是那些具有矩阵和向量公式的问题，而只需用 C 或 Fortran 等标量非交互式语言编写程序所需的时间的一小部分。MATLAB 名称代表矩阵实验室。MATLAB 最初的编写目的是提供对由 LINPACK 和 EISPACK 项目开发的矩阵软件的轻松访问，这两个项目共同代表了矩阵计算软件的最新技术。MATLAB 经过多年的发展，得到了许多用户的投入。在大学环境中，它是数学、工程和科学入门和高级课程的标准教学工具。在工业领域，MATLAB 是高效研究、开发和分析的首选工具。MATLAB 具有一系列称为工具箱的特定于应用程序的解决方案。对于大多数 MATLAB 用户来说非常重要，工具箱允许您学习应用专业技术。工具箱是 MATLAB 函数（M 文件）的综合集合，可扩展 MATLAB 环境以解决特定类别的问题。可用工具箱的领域包括信号处理、控制系统、神经网络、模糊逻辑、小波、仿真等。