# 统计代写|生物统计分析代写Biological statistic analysis代考|MPH203

## 统计代写|生物统计分析代写Biological statistic analysis代考|Linear Contrasts

For our example, we might be interested in comparing the two drugs $D 1$ and $D 2$, for example. One way of doing this is by a simple $t$-test between the corresponding observations. This yields a $t$-value of $t=2.22$ and a $p$-value of $p=0.044$ for a difference of $\hat{\mu}_1-\hat{\mu}_2=1.52$ with a $95 \%$-confidence interval $[0.05,2.98]$. While this approach yields a valid estimate and test, it is inefficient because we completely neglect the information available in the observations of drugs $D 3$ and $D 4$. Specifi-cally, if we assume that the variances are the same in all treatment groups, we could use these additional observations to get a better estimate of the residual variance $\sigma_e^2$ and increase the degrees of freedom.

We consider three example comparisons using our four drugs. We additionally assume that $D 1$ and $D 2$ share the same active component and denote these drugs as ‘Class A’, while $D 3$ and $D 4$ share another component (‘Class B’):

1. as before, compare the drugs in the first class: $D 1$ versus $D 2$;
2. compare the drugs in the second class: $D 3$ versus $D 4$;
3. compare the classes: average of $D 1$ and $D 2$ versus average of $D 3$ and $D 4$.
We can formulate these comparisons in terms of differences of treatment group means; each is an example of a linear contrast:
D1 versus D2: $\mu_1-\mu_2$
D3 versus D4 : $\mu_3-\mu_4$
Class A versus Class B : $\left(\frac{\mu_1+\mu_2}{2}\right)-\left(\frac{\mu_3+\mu_4}{2}\right)$.
Note that a $t$-test for the third comparison requires manual calculation of the corresponding estimates and their standard errors first.

Linear contrasts use all data for estimation and ‘automatically’ lead to the correct $t$ test and confidence interval calculations. Their estimation is one of the main purposes for an experiment:
Contrasts of interest justify the design, not the other way around.
An important task in designing an experiment is to ensure that contrasts of interest are defined beforehand and can be estimated with adequate precision.

## 统计代写|生物统计分析代写Biological statistic analysis代考|Defining Contrasts

Formally, a linear contrast $\Psi(\mathbf{w})$ for a treatment factor with $k$ levels is a linear combination of the group means using a weight vector $\mathbf{w}=\left(w_1, \ldots, w_k\right)$ :
$$\Psi(\mathbf{w})=w_1 \cdot \mu_1+\cdots+w_k \cdot \mu_k,$$
where the entries in the weight vector sum to zero, such that $w_1+\cdots+w_k=0$.
We compare the group means of two sets $X$ and $Y$ of treatment factor levels by selecting the weights $w_i$ as follows:

• the weight of each treatment level not considered is zero: $w_i=0 \Longleftrightarrow i \notin X$ and $i \notin Y$;
• the weights for set $X$ are all positive: $w_i>0 \Longleftrightarrow i \in X$;
• the weights for set $Y$ are all negative: $w_i<0 \Longleftrightarrow i \in Y$;
• the weights sum to zero: $w_1+\cdots+w_k=0$;
• the individual weights $w_i$ determine how the group means of the sets $X$ and $Y$ are averaged; using equal weights with each set corresponds to a simple average of the set’s group means.

The weight vectors for our example contrasts are $\mathbf{w}_1=(+1,-1,0,0)$ for the first contrast, where $X={1}$ and $Y={2} ; \mathbf{w}_2=(0,0,+1,-1)$ for the second, $X={3}$ and $Y={4}$; and $\mathbf{w}_3=(+1 / 2,+1 / 2,-1 / 2,-1 / 2)$ for the third contrast, where $X={1,2}$ and $Y={3,4}$.

# 生物统计分析代考

## 统计代写|生物统计分析代写生物统计分析代考|线性对比

1. 和前面一样，比较第一类药物:$D 1$ vs . $D 2$
2. 比较第二类药物:$D 3$ vs . $D 4$
3. 比较类:$D 1$和$D 2$的平均值vs . $D 3$和$D 4$的平均值
我们可以用治疗组均值的差异来表示这些比较;
D1 vs . D2: $\mu_1-\mu_2$
D3 vs . D4: $\mu_3-\mu_4$
a类vs . B类:$\left(\frac{\mu_1+\mu_2}{2}\right)-\left(\frac{\mu_3+\mu_4}{2}\right)$ .
请注意，第三次比较的$t$ -test需要手动计算相应的估计及其标准误差线性对比使用所有数据进行估计，并“自动”导致正确的$t$测试和置信区间计算。他们的估计是实验的主要目的之一:兴趣的对比证明了设计的合理性，而不是相反。设计实验的一项重要任务是确保事先定义兴趣的对比，并能以足够的精确度进行估计
统计代写|生物统计分析代写生物统计分析代考|定义对比 .形式上，具有$k$水平的处理因子的线性对比$\Psi(\mathbf{w})$是使用权重向量$\mathbf{w}=\left(w_1, \ldots, w_k\right)$:
$$\Psi(\mathbf{w})=w_1 \cdot \mu_1+\cdots+w_k \cdot \mu_k,$$
的组均值的线性组合，其中权重向量中的条目和为零，例如$w_1+\cdots+w_k=0$ .
我们通过选择权重$w_i$比较处理因子水平的两个集合$X$和$Y$的组均值如下:
• 不考虑的每个处理级别的权重为零:$w_i=0 \Longleftrightarrow i \notin X$和$i \notin Y$;
• 集$X$的权重均为正:$w_i>0 \Longleftrightarrow i \in X$
• set的权值 $Y$ 都是负面的: $w_i<0 \Longleftrightarrow i \in Y$
• 权重之和为零: $w_1+\cdots+w_k=0$
• 为个人权重 $w_i$ 确定分组如何意味着集合 $X$ 和 $Y$ 平均;对每个集合使用相同的权重对应于集合的组均值的简单平均值。

我们的例子对比的权重向量是$\mathbf{w}_1=(+1,-1,0,0)$用于第一个对比，$X={1}$和$Y={2} ; \mathbf{w}_2=(0,0,+1,-1)$用于第二个对比，$X={3}$和$Y={4}$;第三个对比是$\mathbf{w}_3=(+1 / 2,+1 / 2,-1 / 2,-1 / 2)$，其中$X={1,2}$和$Y={3,4}$ .

myassignments-help数学代考价格说明

1、客户需提供物理代考的网址，相关账户，以及课程名称，Textbook等相关资料~客服会根据作业数量和持续时间给您定价~使收费透明，让您清楚的知道您的钱花在什么地方。

2、数学代写一般每篇报价约为600—1000rmb，费用根据持续时间、周作业量、成绩要求有所浮动(持续时间越长约便宜、周作业量越多约贵、成绩要求越高越贵)，报价后价格觉得合适，可以先付一周的款，我们帮你试做，满意后再继续，遇到Fail全额退款。

3、myassignments-help公司所有MATH作业代写服务支持付半款，全款，周付款，周付款一方面方便大家查阅自己的分数，一方面也方便大家资金周转，注意:每周固定周一时先预付下周的定金，不付定金不予继续做。物理代写一次性付清打9.5折。

Math作业代写、数学代写常见问题

myassignments-help擅长领域包含但不是全部:

myassignments-help服务请添加我们官网的客服或者微信/QQ，我们的服务覆盖：Assignment代写、Business商科代写、CS代考、Economics经济学代写、Essay代写、Finance金融代写、Math数学代写、report代写、R语言代考、Statistics统计学代写、物理代考、作业代写、加拿大代考、加拿大统计代写、北美代写、北美作业代写、北美统计代考、商科Essay代写、商科代考、数学代考、数学代写、数学作业代写、physics作业代写、物理代写、数据分析代写、新西兰代写、澳洲Essay代写、澳洲代写、澳洲作业代写、澳洲统计代写、澳洲金融代写、留学生课业指导、经济代写、统计代写、统计作业代写、美国Essay代写、美国代考、美国数学代写、美国统计代写、英国Essay代写、英国代考、英国作业代写、英国数学代写、英国统计代写、英国金融代写、论文代写、金融代考、金融作业代写。

Scroll to Top