单阶段集群抽样

发布于 2025-01-30 11:06:43 字数 259 浏览 3 评论 0原文

选择一个尺寸1,000名学生的单阶段群集样本,然后计算两个变量的平均值及其95%的置信区间。

变量1是类号码,V2是类中的学生编号,V3和V4是测试结果。

c1 <- sample(unique(test$V1), size=1000, replace=F)
c1_s <- test[test$V1 %in% c1,]

我已经完成了采样的编码,但是我需要在计算V3和V4及其95%CI的平均值的编码方面提供帮助。

Choose a single stage cluster sample of size 1,000 students and then calculate the mean value for both variables along with their 95% confidence interval.

Variable 1 is the class number, V2 is the Student number in the class, V3 and V4 is the test results.

c1 <- sample(unique(test$V1), size=1000, replace=F)
c1_s <- test[test$V1 %in% c1,]

I have done the coding for sampling, but I need help with the coding for calculating the mean value for V3 and V4 along with their 95% CI.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文