r语言p值%3c2e-16,Calculating p Values(R软件计算p值)

本文介绍了如何使用R语言计算p值,涵盖了正态分布和t分布的情况。通过示例详细解释了如何计算Z-score和t-score,并展示了在不同情况下计算p值的步骤,包括涉及样本均值、标准差和自由度的计算。
摘要由CSDN通过智能技术生成

Calculating p Values

Here we look at some examples of calculating p values. The examples

are for both normal and t distributions. We assume that you

can enter

data and know the commands associated

with

We look at the steps necessary to calculate the p-value for a

particular test. In the interest of simplicity we only look at a

two sided test, and we focus on one example. Here we want to show

that the mean is not close to a fixed value, a.

H0: mux = a,

Ha: mux not = a,

The p value is

calculated for a particular sample mean. Here we assume that we

obtained a sample

mean, x and want to find

its p value. It is the

probability that we would obtain a given sample mean that is

greater than the absolute value of its Z-score or less than the

negative of the absolute value of its Z-score.

For the special case of a normal distribution we also need the

standard deviation. We will assume that we are given the standard

deviation and call it s. The calculation

for the p value can be

done in several of ways. We will look at two ways here. The first

way is to convert the sample means to their associated Z-score. The

other way is to simply specify the standard deviation and let the

computer do the conversion. At first glance it may seem like a no

brainer, and we should just use the second method. Unfortunately,

when using the t-distribution we need to

convert to the t-score, so it is a good

idea to know both ways.

We first look at how to calculate

the p-value using the Z-score. The

Z-score is found by assumi

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值