Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The NHANESraw dataset from the NHANES package in R contains survey results from many years. To obtain a baseline observation for an individual from the

The NHANESraw dataset from the NHANES package in R contains survey results from many years. To obtain a baseline observation for an individual from the 2011-12 survey, we have:

# If the packages are not installed, we have the following. # install.packages("tidyverse") install.packages("survey") install.packages("NHANES") # The following are the packages that are needed. # library(tidyverse) library(survey) library(NHANES) # This will provide the baseline observations from the 2011-12 survey. # small.nhanes <- na.omit(NHANESraw[NHANESraw$SurveyYr == "2011_12" & NHANESraw$Age > 17, c(1, 3, 4, 8:11, 13, 24, 61, 77)]) small.nhanes <- small.nhanes %>% group_by(ID) %>% filter(row_number() == 1) small.nhanes 

This will result in 4581 observations from the 2011-12 survey with 11 columns. Calculate the stratum-specific sample size nj : j = 1, 2, . . . , 14 and the overall sample size n.

Please note the following.

  • This is a sample from a larger dataset, but we'll use this data as a population instead
  • SDMVSTRA are the strata and there are 14 strata here

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Statistical Techniques in Business and Economics

Authors: Douglas A. Lind, William G Marchal

17th edition

1259666360, 978-1259666360

More Books

Students also viewed these Mathematics questions

Question

How many multiples of 4 are there between 10 and 250?

Answered: 1 week ago