<!DOCTYPE html>
<html lang="" xml:lang="">
<head>

  <meta charset="utf-8" />
  <meta http-equiv="X-UA-Compatible" content="IE=edge" />
  <title>Progress in International Reading Literacy Study (PIRLS) | Analyze Survey Data for Free</title>
  <meta name="description" content="Progress in International Reading Literacy Study (PIRLS) | Analyze Survey Data for Free" />
  <meta name="generator" content="bookdown 0.41 and GitBook 2.6.7" />

  <meta property="og:title" content="Progress in International Reading Literacy Study (PIRLS) | Analyze Survey Data for Free" />
  <meta property="og:type" content="book" />
  
  
  <meta name="github-repo" content="ajdamico/asdfree" />

  <meta name="twitter:card" content="summary" />
  <meta name="twitter:title" content="Progress in International Reading Literacy Study (PIRLS) | Analyze Survey Data for Free" />
  
  
  




  <meta name="viewport" content="width=device-width, initial-scale=1" />
  <meta name="apple-mobile-web-app-capable" content="yes" />
  <meta name="apple-mobile-web-app-status-bar-style" content="black" />
  
  
<link rel="prev" href="programme-for-the-international-assessment-of-adult-competencies-piaac.html"/>
<link rel="next" href="public-libraries-survey-pls.html"/>
<script src="libs/jquery-3.6.0/jquery-3.6.0.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/fuse.js@6.4.6/dist/fuse.min.js"></script>
<link href="libs/gitbook-2.6.7/css/style.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-table.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-bookdown.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-highlight.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-search.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-fontsettings.css" rel="stylesheet" />
<link href="libs/gitbook-2.6.7/css/plugin-clipboard.css" rel="stylesheet" />








<link href="libs/anchor-sections-1.1.0/anchor-sections.css" rel="stylesheet" />
<link href="libs/anchor-sections-1.1.0/anchor-sections-hash.css" rel="stylesheet" />
<script src="libs/anchor-sections-1.1.0/anchor-sections.js"></script>


<style type="text/css">
pre > code.sourceCode { white-space: pre; position: relative; }
pre > code.sourceCode > span { display: inline-block; line-height: 1.25; }
pre > code.sourceCode > span:empty { height: 1.2em; }
.sourceCode { overflow: visible; }
code.sourceCode > span { color: inherit; text-decoration: inherit; }
pre.sourceCode { margin: 0; }
@media screen {
div.sourceCode { overflow: auto; }
}
@media print {
pre > code.sourceCode { white-space: pre-wrap; }
pre > code.sourceCode > span { text-indent: -5em; padding-left: 5em; }
}
pre.numberSource code
  { counter-reset: source-line 0; }
pre.numberSource code > span
  { position: relative; left: -4em; counter-increment: source-line; }
pre.numberSource code > span > a:first-child::before
  { content: counter(source-line);
    position: relative; left: -1em; text-align: right; vertical-align: baseline;
    border: none; display: inline-block;
    -webkit-touch-callout: none; -webkit-user-select: none;
    -khtml-user-select: none; -moz-user-select: none;
    -ms-user-select: none; user-select: none;
    padding: 0 4px; width: 4em;
    color: #aaaaaa;
  }
pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa;  padding-left: 4px; }
div.sourceCode
  {   }
@media screen {
pre > code.sourceCode > span > a:first-child::before { text-decoration: underline; }
}
code span.al { color: #ff0000; font-weight: bold; } /* Alert */
code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */
code span.at { color: #7d9029; } /* Attribute */
code span.bn { color: #40a070; } /* BaseN */
code span.bu { color: #008000; } /* BuiltIn */
code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */
code span.ch { color: #4070a0; } /* Char */
code span.cn { color: #880000; } /* Constant */
code span.co { color: #60a0b0; font-style: italic; } /* Comment */
code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */
code span.do { color: #ba2121; font-style: italic; } /* Documentation */
code span.dt { color: #902000; } /* DataType */
code span.dv { color: #40a070; } /* DecVal */
code span.er { color: #ff0000; font-weight: bold; } /* Error */
code span.ex { } /* Extension */
code span.fl { color: #40a070; } /* Float */
code span.fu { color: #06287e; } /* Function */
code span.im { color: #008000; font-weight: bold; } /* Import */
code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */
code span.kw { color: #007020; font-weight: bold; } /* Keyword */
code span.op { color: #666666; } /* Operator */
code span.ot { color: #007020; } /* Other */
code span.pp { color: #bc7a00; } /* Preprocessor */
code span.sc { color: #4070a0; } /* SpecialChar */
code span.ss { color: #bb6688; } /* SpecialString */
code span.st { color: #4070a0; } /* String */
code span.va { color: #19177c; } /* Variable */
code span.vs { color: #4070a0; } /* VerbatimString */
code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */
</style>

<style type="text/css">
  
  div.hanging-indent{margin-left: 1.5em; text-indent: -1.5em;}
</style>

<link rel="stylesheet" href="style.css" type="text/css" />
</head>

<body>



  <div class="book without-animation with-summary font-size-2 font-family-1" data-basepath=".">

    <div class="book-summary">
      <nav role="navigation">

<ul class="summary">
<li><a href="./">Analyze Survey Data for Free</a></li>
<b><li><a href="https://www.eventbrite.com/e/1032151692497">Free 3hr Workshop @ DCPL Nov 13</a></li></b>

<li class="divider"></li>
<li class="chapter" data-level="" data-path="index.html"><a href="index.html"><i class="fa fa-check"></i>Forty-Nine Public Microdatasets To Analyze Before You Die From An Easy To Type Website</a></li>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html"><i class="fa fa-check"></i>Trend Analysis of Complex Survey Data</a>
<ul>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html#download-import-preparation"><i class="fa fa-check"></i>Download, Import, Preparation</a></li>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html#append-polynomials-to-each-year"><i class="fa fa-check"></i>Append Polynomials to Each Year</a></li>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html#unadjusted-analysis-examples"><i class="fa fa-check"></i>Unadjusted Analysis Examples</a></li>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html#calculate-joinpoints-needed"><i class="fa fa-check"></i>Calculate Joinpoints Needed</a></li>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html#calculate-predicted-marginals"><i class="fa fa-check"></i>Calculate Predicted Marginals</a></li>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html#identify-joinpoints-or-breakpoints"><i class="fa fa-check"></i>Identify Joinpoint(s) or Breakpoint(s)</a></li>
<li class="chapter" data-level="" data-path="trend-analysis-of-complex-survey-data.html"><a href="trend-analysis-of-complex-survey-data.html#interpret-and-conclude"><i class="fa fa-check"></i>Interpret and Conclude</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html"><i class="fa fa-check"></i>American Community Survey (ACS)</a>
<ul>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#download-import-preparation-1"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#save-locally"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#survey-design-definition"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#variable-recoding"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#analysis-examples-with-the-survey-library"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#unweighted-counts"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#weighted-counts"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#descriptive-statistics"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#subsetting"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#measures-of-uncertainty"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#regression-models-and-tests-of-association"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#replication-example"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#poverty-and-inequality-estimation-with-convey"><i class="fa fa-check"></i>Poverty and Inequality Estimation with <code>convey</code>  </a></li>
<li class="chapter" data-level="" data-path="american-community-survey-acs.html"><a href="american-community-survey-acs.html#analysis-examples-with-srvyr"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html"><i class="fa fa-check"></i>Area Health Resources Files (AHRF)</a>
<ul>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#download-import-preparation-2"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#save-locally-1"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#variable-recoding-1"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#analysis-examples-with-base-r"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#unweighted-counts-1"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#descriptive-statistics-1"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#subsetting-1"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#measures-of-uncertainty-1"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#regression-models-and-tests-of-association-1"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#replication-example-1"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#analysis-examples-with-dplyr"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#analysis-examples-with-data.table"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="area-health-resources-files-ahrf.html"><a href="area-health-resources-files-ahrf.html#analysis-examples-with-duckdb"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html"><i class="fa fa-check"></i>American Housing Survey (AHS)</a>
<ul>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#download-import-preparation-3"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#save-locally-2"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#survey-design-definition-1"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#variable-recoding-2"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#analysis-examples-with-the-survey-library-1"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#unweighted-counts-2"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#weighted-counts-1"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#descriptive-statistics-2"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#subsetting-2"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#measures-of-uncertainty-2"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#regression-models-and-tests-of-association-2"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#replication-example-2"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="american-housing-survey-ahs.html"><a href="american-housing-survey-ahs.html#analysis-examples-with-srvyr-1"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html"><i class="fa fa-check"></i>American National Election Studies (ANES)</a>
<ul>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#function-definitions"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#download-import-preparation-4"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#save-locally-3"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#survey-design-definition-2"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#variable-recoding-3"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#analysis-examples-with-the-survey-library-2"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#unweighted-counts-3"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#weighted-counts-2"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#descriptive-statistics-3"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#subsetting-3"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#measures-of-uncertainty-3"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#regression-models-and-tests-of-association-3"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#replication-example-3"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="american-national-election-studies-anes.html"><a href="american-national-election-studies-anes.html#analysis-examples-with-srvyr-2"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html"><i class="fa fa-check"></i>American Time Use Survey (ATUS)</a>
<ul>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#function-definitions-1"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#download-import-preparation-5"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#save-locally-4"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#survey-design-definition-3"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#variable-recoding-4"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#analysis-examples-with-the-survey-library-3"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#unweighted-counts-4"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#weighted-counts-3"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#descriptive-statistics-4"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#subsetting-4"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#measures-of-uncertainty-4"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#regression-models-and-tests-of-association-4"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#replication-example-4"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="american-time-use-survey-atus.html"><a href="american-time-use-survey-atus.html#analysis-examples-with-srvyr-3"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html"><i class="fa fa-check"></i>Behavioral Risk Factor Surveillance System (BRFSS)</a>
<ul>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#download-import-preparation-6"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#save-locally-5"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#survey-design-definition-4"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#variable-recoding-5"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#analysis-examples-with-the-survey-library-4"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#unweighted-counts-5"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#weighted-counts-4"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#descriptive-statistics-5"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#subsetting-5"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#measures-of-uncertainty-5"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#regression-models-and-tests-of-association-5"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#replication-example-5"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="behavioral-risk-factor-surveillance-system-brfss.html"><a href="behavioral-risk-factor-surveillance-system-brfss.html#analysis-examples-with-srvyr-4"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html"><i class="fa fa-check"></i>Consumer Expenditure Survey (CES)</a>
<ul>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#download-import-preparation-7"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#save-locally-6"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#survey-design-definition-5"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#variable-recoding-6"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#analysis-examples-with-the-survey-library-5"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#unweighted-counts-6"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#weighted-counts-5"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#descriptive-statistics-6"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#subsetting-6"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#measures-of-uncertainty-6"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#regression-models-and-tests-of-association-6"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="consumer-expenditure-survey-ces.html"><a href="consumer-expenditure-survey-ces.html#replication-example-6"><i class="fa fa-check"></i>Replication Example</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html"><i class="fa fa-check"></i>California Health Interview Survey (CHIS)</a>
<ul>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#function-definitions-2"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#download-import-preparation-8"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#save-locally-7"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#survey-design-definition-6"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#variable-recoding-7"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#analysis-examples-with-the-survey-library-6"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#unweighted-counts-7"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#weighted-counts-6"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#descriptive-statistics-7"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#subsetting-7"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#measures-of-uncertainty-7"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#regression-models-and-tests-of-association-7"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#replication-example-7"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="california-health-interview-survey-chis.html"><a href="california-health-interview-survey-chis.html#analysis-examples-with-srvyr-5"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html"><i class="fa fa-check"></i>Census of Governments (COG)</a>
<ul>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#download-import-preparation-9"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#save-locally-8"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#variable-recoding-8"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#analysis-examples-with-base-r-1"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#unweighted-counts-8"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#descriptive-statistics-8"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#subsetting-8"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#measures-of-uncertainty-8"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#regression-models-and-tests-of-association-8"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#replication-example-8"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#analysis-examples-with-dplyr-1"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#analysis-examples-with-data.table-1"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="census-of-governments-cog.html"><a href="census-of-governments-cog.html#analysis-examples-with-duckdb-1"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html"><i class="fa fa-check"></i>Current Population Survey (CPS)</a>
<ul>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#download-import-preparation-10"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#save-locally-9"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#survey-design-definition-7"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#variable-recoding-9"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#analysis-examples-with-the-survey-library-7"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#unweighted-counts-9"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#weighted-counts-7"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#descriptive-statistics-9"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#subsetting-9"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#measures-of-uncertainty-9"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#regression-models-and-tests-of-association-9"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#replication-example-9"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#poverty-and-inequality-estimation-with-convey-1"><i class="fa fa-check"></i>Poverty and Inequality Estimation with <code>convey</code>  </a></li>
<li class="chapter" data-level="" data-path="current-population-survey-cps.html"><a href="current-population-survey-cps.html#analysis-examples-with-srvyr-6"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html"><i class="fa fa-check"></i>Exame Nacional de Desempenho de Estudantes (ENADE)</a>
<ul>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#download-import-preparation-11"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#save-locally-10"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#variable-recoding-10"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#analysis-examples-with-base-r-2"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#unweighted-counts-10"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#descriptive-statistics-10"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#subsetting-10"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#measures-of-uncertainty-10"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#regression-models-and-tests-of-association-10"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#replication-example-10"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#analysis-examples-with-dplyr-2"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#analysis-examples-with-data.table-2"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="exame-nacional-de-desempenho-de-estudantes-enade.html"><a href="exame-nacional-de-desempenho-de-estudantes-enade.html#analysis-examples-with-duckdb-2"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html"><i class="fa fa-check"></i>Exame Nacional do Ensino Medio (ENEM)</a>
<ul>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#download-import-preparation-12"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#save-locally-11"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#variable-recoding-11"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#analysis-examples-with-base-r-3"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#unweighted-counts-11"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#descriptive-statistics-11"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#subsetting-11"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#measures-of-uncertainty-11"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#regression-models-and-tests-of-association-11"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#replication-example-11"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#analysis-examples-with-dplyr-3"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#analysis-examples-with-data.table-3"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="exame-nacional-do-ensino-medio-enem.html"><a href="exame-nacional-do-ensino-medio-enem.html#analysis-examples-with-duckdb-3"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html"><i class="fa fa-check"></i>European Social Survey (ESS)</a>
<ul>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#download-import-preparation-13"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#save-locally-12"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#survey-design-definition-8"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#variable-recoding-12"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#analysis-examples-with-the-survey-library-8"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#unweighted-counts-12"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#weighted-counts-8"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#descriptive-statistics-12"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#subsetting-12"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#measures-of-uncertainty-12"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#regression-models-and-tests-of-association-12"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#replication-example-12"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="european-social-survey-ess.html"><a href="european-social-survey-ess.html#analysis-examples-with-srvyr-7"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html"><i class="fa fa-check"></i>FDA Adverse Event Reporting System (FAERS)</a>
<ul>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#function-definitions-3"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#download-import-preparation-14"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#save-locally-13"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#variable-recoding-13"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#analysis-examples-with-base-r-4"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#unweighted-counts-13"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#descriptive-statistics-13"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#subsetting-13"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#measures-of-uncertainty-13"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#regression-models-and-tests-of-association-13"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#replication-example-13"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#analysis-examples-with-dplyr-4"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#analysis-examples-with-data.table-4"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="fda-adverse-event-reporting-system-faers.html"><a href="fda-adverse-event-reporting-system-faers.html#analysis-examples-with-duckdb-4"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html"><i class="fa fa-check"></i>General Social Survey (GSS)</a>
<ul>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#download-import-preparation-15"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#save-locally-14"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#survey-design-definition-9"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#variable-recoding-14"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#analysis-examples-with-the-survey-library-9"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#unweighted-counts-14"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#weighted-counts-9"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#descriptive-statistics-14"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#subsetting-14"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#measures-of-uncertainty-14"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#regression-models-and-tests-of-association-14"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#replication-example-14"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="general-social-survey-gss.html"><a href="general-social-survey-gss.html#analysis-examples-with-srvyr-8"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html"><i class="fa fa-check"></i>Health and Retirement Study (HRS)</a>
<ul>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#download-import-preparation-16"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#save-locally-15"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#survey-design-definition-10"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#variable-recoding-15"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#analysis-examples-with-the-survey-library-10"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#unweighted-counts-15"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#weighted-counts-10"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#descriptive-statistics-15"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#subsetting-15"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#measures-of-uncertainty-15"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#regression-models-and-tests-of-association-15"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#replication-example-15"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="health-and-retirement-study-hrs.html"><a href="health-and-retirement-study-hrs.html#analysis-examples-with-srvyr-9"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html"><i class="fa fa-check"></i>Medicare Current Beneficiary Survey (MCBS)</a>
<ul>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#download-import-preparation-17"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#save-locally-16"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#survey-design-definition-11"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#variable-recoding-16"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#analysis-examples-with-the-survey-library-11"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#unweighted-counts-16"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#weighted-counts-11"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#descriptive-statistics-16"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#subsetting-16"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#measures-of-uncertainty-16"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#regression-models-and-tests-of-association-16"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#replication-example-16"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="medicare-current-beneficiary-survey-mcbs.html"><a href="medicare-current-beneficiary-survey-mcbs.html#analysis-examples-with-srvyr-10"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html"><i class="fa fa-check"></i>Medical Expenditure Panel Survey (MEPS)</a>
<ul>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#function-definitions-4"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#download-import-preparation-18"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#save-locally-17"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#survey-design-definition-12"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#variable-recoding-17"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#analysis-examples-with-the-survey-library-12"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#unweighted-counts-17"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#weighted-counts-12"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#descriptive-statistics-17"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#subsetting-17"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#measures-of-uncertainty-17"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#regression-models-and-tests-of-association-17"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#replication-example-17"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="medical-expenditure-panel-survey-meps.html"><a href="medical-expenditure-panel-survey-meps.html#analysis-examples-with-srvyr-11"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html"><i class="fa fa-check"></i>Medical Large Claims Experience Study (MLCES)</a>
<ul>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#download-import-preparation-19"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#save-locally-18"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#variable-recoding-18"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#analysis-examples-with-base-r-5"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#unweighted-counts-18"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#descriptive-statistics-18"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#subsetting-18"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#measures-of-uncertainty-18"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#regression-models-and-tests-of-association-18"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#replication-example-18"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#analysis-examples-with-dplyr-5"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#analysis-examples-with-data.table-5"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="medical-large-claims-experience-study-mlces.html"><a href="medical-large-claims-experience-study-mlces.html#analysis-examples-with-duckdb-5"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html"><i class="fa fa-check"></i>National Agricultural Workers Survey (NAWS)</a>
<ul>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#download-import-preparation-20"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#save-locally-19"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#survey-design-definition-13"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#variable-recoding-19"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#analysis-examples-with-the-survey-library-13"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#unweighted-counts-19"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#weighted-counts-13"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#descriptive-statistics-19"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#subsetting-19"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#measures-of-uncertainty-19"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#regression-models-and-tests-of-association-19"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#replication-example-19"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-agricultural-workers-survey-naws.html"><a href="national-agricultural-workers-survey-naws.html#analysis-examples-with-srvyr-12"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html"><i class="fa fa-check"></i>National Beneficiary Survey (NBS)</a>
<ul>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#download-import-preparation-21"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#save-locally-20"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#survey-design-definition-14"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#variable-recoding-20"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#analysis-examples-with-the-survey-library-14"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#unweighted-counts-20"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#weighted-counts-14"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#descriptive-statistics-20"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#subsetting-20"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#measures-of-uncertainty-20"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#regression-models-and-tests-of-association-20"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#replication-example-20"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-beneficiary-survey-nbs.html"><a href="national-beneficiary-survey-nbs.html#analysis-examples-with-srvyr-13"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html"><i class="fa fa-check"></i>National Crime Victimization Survey (NCVS)</a>
<ul>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#function-definitions-5"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#download-import-preparation-22"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#save-locally-21"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#survey-design-definition-15"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#variable-recoding-21"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#analysis-examples-with-the-survey-library-15"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#unweighted-counts-21"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#weighted-counts-15"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#descriptive-statistics-21"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#subsetting-21"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#measures-of-uncertainty-21"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#regression-models-and-tests-of-association-21"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#replication-example-21"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-crime-victimization-survey-ncvs.html"><a href="national-crime-victimization-survey-ncvs.html#analysis-examples-with-srvyr-14"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html"><i class="fa fa-check"></i>National Financial Capability Study (NFCS)</a>
<ul>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#download-import-preparation-23"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#save-locally-22"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#survey-design-definition-16"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#variable-recoding-22"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#analysis-examples-with-the-survey-library-16"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#unweighted-counts-22"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#weighted-counts-16"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#descriptive-statistics-22"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#subsetting-22"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#measures-of-uncertainty-22"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#regression-models-and-tests-of-association-22"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#replication-example-22"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-financial-capability-study-nfcs.html"><a href="national-financial-capability-study-nfcs.html#analysis-examples-with-srvyr-15"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html"><i class="fa fa-check"></i>National Health and Nutrition Examination Survey (NHANES)</a>
<ul>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#download-import-preparation-24"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#save-locally-23"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#survey-design-definition-17"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#variable-recoding-23"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#analysis-examples-with-the-survey-library-17"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#unweighted-counts-23"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#weighted-counts-17"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#descriptive-statistics-23"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#subsetting-23"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#measures-of-uncertainty-23"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#regression-models-and-tests-of-association-23"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#direct-method-of-age-adjustment-replication-example"><i class="fa fa-check"></i>Direct Method of Age-Adjustment Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-health-and-nutrition-examination-survey-nhanes.html"><a href="national-health-and-nutrition-examination-survey-nhanes.html#analysis-examples-with-srvyr-16"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html"><i class="fa fa-check"></i>National Health Interview Survey (NHIS)</a>
<ul>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#function-definitions-6"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#download-import-preparation-25"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#save-locally-24"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#survey-design-definition-18"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#variable-recoding-24"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#analysis-examples-with-the-survey-library-18"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#unweighted-counts-24"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#weighted-counts-18"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#descriptive-statistics-24"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#subsetting-24"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#measures-of-uncertainty-24"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#regression-models-and-tests-of-association-24"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-health-interview-survey-nhis.html"><a href="national-health-interview-survey-nhis.html#replication-example-23"><i class="fa fa-check"></i>Replication Example</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html"><i class="fa fa-check"></i>National Household Travel Survey (NHTS)</a>
<ul>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#download-import-preparation-26"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#save-locally-25"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#survey-design-definition-19"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#variable-recoding-25"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#analysis-examples-with-the-survey-library-19"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#unweighted-counts-25"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#weighted-counts-19"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#descriptive-statistics-25"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#subsetting-25"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#measures-of-uncertainty-25"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#regression-models-and-tests-of-association-25"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#replication-example-24"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-household-travel-survey-nhts.html"><a href="national-household-travel-survey-nhts.html#analysis-examples-with-srvyr-17"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html"><i class="fa fa-check"></i>National Immunization Survey (NIS)</a>
<ul>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#download-import-preparation-27"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#save-locally-26"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#survey-design-definition-20"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#variable-recoding-26"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#analysis-examples-with-the-survey-library-20"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#unweighted-counts-26"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#weighted-counts-20"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#descriptive-statistics-26"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#subsetting-26"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#measures-of-uncertainty-26"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#regression-models-and-tests-of-association-26"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#replication-example-25"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-immunization-survey-nis.html"><a href="national-immunization-survey-nis.html#analysis-examples-with-srvyr-18"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html"><i class="fa fa-check"></i>National Plan and Provider Enumeration System (NPPES)</a>
<ul>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#download-import-preparation-28"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#save-locally-27"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#variable-recoding-27"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#analysis-examples-with-base-r-6"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#unweighted-counts-27"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#descriptive-statistics-27"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#subsetting-27"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#measures-of-uncertainty-27"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#regression-models-and-tests-of-association-27"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#analysis-examples-with-dplyr-6"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#analysis-examples-with-data.table-6"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="national-plan-and-provider-enumeration-system-nppes.html"><a href="national-plan-and-provider-enumeration-system-nppes.html#analysis-examples-with-duckdb-6"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html"><i class="fa fa-check"></i>National Survey of Children’s Health (NSCH)</a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#function-definitions-7"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#download-import-preparation-29"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#save-locally-28"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#survey-design-definition-21"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#variable-recoding-28"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#analysis-examples-with-the-survey-library-21"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#unweighted-counts-28"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#weighted-counts-21"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#descriptive-statistics-28"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#subsetting-28"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#measures-of-uncertainty-28"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#regression-models-and-tests-of-association-28"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-of-childrens-health-nsch.html"><a href="national-survey-of-childrens-health-nsch.html#replication-example-26"><i class="fa fa-check"></i>Replication Example</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html"><i class="fa fa-check"></i>National Survey on Drug Use and Health (NSDUH)</a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#download-import-preparation-30"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#save-locally-29"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#survey-design-definition-22"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#variable-recoding-29"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#analysis-examples-with-the-survey-library-22"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#unweighted-counts-29"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#weighted-counts-22"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#descriptive-statistics-29"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#subsetting-29"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#measures-of-uncertainty-29"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#regression-models-and-tests-of-association-29"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#replication-example-27"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-survey-on-drug-use-and-health-nsduh.html"><a href="national-survey-on-drug-use-and-health-nsduh.html#analysis-examples-with-srvyr-19"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html"><i class="fa fa-check"></i>National Survey of Family Growth (NSFG)</a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#download-import-preparation-31"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#save-locally-30"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#survey-design-definition-23"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#variable-recoding-30"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#analysis-examples-with-the-survey-library-23"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#unweighted-counts-30"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#weighted-counts-23"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#descriptive-statistics-30"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#subsetting-30"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#measures-of-uncertainty-30"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#regression-models-and-tests-of-association-30"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#replication-example-28"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-survey-of-family-growth-nsfg.html"><a href="national-survey-of-family-growth-nsfg.html#analysis-examples-with-srvyr-20"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html"><i class="fa fa-check"></i>National Sample Survey of Registered Nurses (NSSRN)</a>
<ul>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#download-import-preparation-32"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#save-locally-31"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#survey-design-definition-24"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#variable-recoding-31"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#analysis-examples-with-the-survey-library-24"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#unweighted-counts-31"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#weighted-counts-24"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#descriptive-statistics-31"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#subsetting-31"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#measures-of-uncertainty-31"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#regression-models-and-tests-of-association-31"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#replication-example-29"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="national-sample-survey-of-registered-nurses-nssrn.html"><a href="national-sample-survey-of-registered-nurses-nssrn.html#analysis-examples-with-srvyr-21"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html"><i class="fa fa-check"></i>New York City Housing and Vacancy Survey (NYCHVS)</a>
<ul>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#function-definitions-8"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#download-import-preparation-33"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#save-locally-32"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#survey-design-definition-25"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#variable-recoding-32"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#analysis-examples-with-the-survey-library-25"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#unweighted-counts-32"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#weighted-counts-25"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#descriptive-statistics-32"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#subsetting-32"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#measures-of-uncertainty-32"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#regression-models-and-tests-of-association-32"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#replication-example-30"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="new-york-city-housing-and-vacancy-survey-nychvs.html"><a href="new-york-city-housing-and-vacancy-survey-nychvs.html#analysis-examples-with-srvyr-22"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html"><i class="fa fa-check"></i>Pew Research Center (PEW)</a>
<ul>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#download-import-preparation-34"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#save-locally-33"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#survey-design-definition-26"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#variable-recoding-33"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#analysis-examples-with-the-survey-library-26"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#unweighted-counts-33"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#weighted-counts-26"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#descriptive-statistics-33"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#subsetting-33"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#measures-of-uncertainty-33"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#regression-models-and-tests-of-association-33"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#replication-example-31"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="pew-research-center-pew.html"><a href="pew-research-center-pew.html#analysis-examples-with-srvyr-23"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><i class="fa fa-check"></i>Programme for the International Assessment of Adult Competencies (PIAAC)</a>
<ul>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#download-import-preparation-35"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#save-locally-34"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#survey-design-definition-27"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#variable-recoding-34"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#analysis-examples-with-the-survey-library-27"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#unweighted-counts-34"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#weighted-counts-27"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#descriptive-statistics-34"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#subsetting-34"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#measures-of-uncertainty-34"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#regression-models-and-tests-of-association-34"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="programme-for-the-international-assessment-of-adult-competencies-piaac.html"><a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html#replication-example-32"><i class="fa fa-check"></i>Replication Example</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html"><i class="fa fa-check"></i>Progress in International Reading Literacy Study (PIRLS)</a>
<ul>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#function-definitions-9"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#download-import-preparation-36"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#save-locally-35"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#survey-design-definition-28"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#variable-recoding-35"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#analysis-examples-with-the-survey-library-28"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#unweighted-counts-35"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#weighted-counts-28"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#descriptive-statistics-35"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#subsetting-35"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#measures-of-uncertainty-35"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#regression-models-and-tests-of-association-35"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="progress-in-international-reading-literacy-study-pirls.html"><a href="progress-in-international-reading-literacy-study-pirls.html#replication-example-33"><i class="fa fa-check"></i>Replication Example</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html"><i class="fa fa-check"></i>Public Libraries Survey (PLS)</a>
<ul>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#download-import-preparation-37"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#save-locally-36"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#variable-recoding-36"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#analysis-examples-with-base-r-7"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#unweighted-counts-36"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#descriptive-statistics-36"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#subsetting-36"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#measures-of-uncertainty-36"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#regression-models-and-tests-of-association-36"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#replication-example-34"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#analysis-examples-with-dplyr-7"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#analysis-examples-with-data.table-7"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="public-libraries-survey-pls.html"><a href="public-libraries-survey-pls.html#analysis-examples-with-duckdb-7"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><i class="fa fa-check"></i>Pesquisa Nacional por Amostra de Domicilios (PNAD)</a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#download-import-preparation-38"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#save-locally-37"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#survey-design-definition-29"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#variable-recoding-37"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#analysis-examples-with-the-survey-library-29"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#unweighted-counts-37"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#weighted-counts-29"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#descriptive-statistics-37"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#subsetting-37"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#measures-of-uncertainty-37"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#regression-models-and-tests-of-association-37"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#replication-example-35"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#poverty-and-inequality-estimation-with-convey-2"><i class="fa fa-check"></i>Poverty and Inequality Estimation with <code>convey</code>  </a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-por-amostra-de-domicilios-pnad.html"><a href="pesquisa-nacional-por-amostra-de-domicilios-pnad.html#analysis-examples-with-srvyr-24"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html"><i class="fa fa-check"></i>Pesquisa Nacional de Saude (PNS)</a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#download-import-preparation-39"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#save-locally-38"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#survey-design-definition-30"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#variable-recoding-38"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#analysis-examples-with-the-survey-library-30"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#unweighted-counts-38"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#weighted-counts-30"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#descriptive-statistics-38"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#subsetting-38"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#measures-of-uncertainty-38"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#regression-models-and-tests-of-association-38"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#replication-example-36"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="pesquisa-nacional-de-saude-pns.html"><a href="pesquisa-nacional-de-saude-pns.html#analysis-examples-with-srvyr-25"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html"><i class="fa fa-check"></i>Pesquisa de Orcamentos Familiares (POF)</a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#download-import-preparation-40"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#save-locally-39"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#survey-design-definition-31"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#variable-recoding-39"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#analysis-examples-with-the-survey-library-31"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#unweighted-counts-39"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#weighted-counts-31"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#descriptive-statistics-39"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#subsetting-39"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#measures-of-uncertainty-39"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#regression-models-and-tests-of-association-39"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#replication-example-37"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#poverty-and-inequality-estimation-with-convey-3"><i class="fa fa-check"></i>Poverty and Inequality Estimation with <code>convey</code>  </a></li>
<li class="chapter" data-level="" data-path="pesquisa-de-orcamentos-familiares-pof.html"><a href="pesquisa-de-orcamentos-familiares-pof.html#analysis-examples-with-srvyr-26"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html"><i class="fa fa-check"></i>Residential Energy Consumption Survey (RECS)</a>
<ul>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#download-import-preparation-41"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#save-locally-40"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#survey-design-definition-32"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#variable-recoding-40"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#analysis-examples-with-the-survey-library-32"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#unweighted-counts-40"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#weighted-counts-32"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#descriptive-statistics-40"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#subsetting-40"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#measures-of-uncertainty-40"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#regression-models-and-tests-of-association-40"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#replication-example-38"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="residential-energy-consumption-survey-recs.html"><a href="residential-energy-consumption-survey-recs.html#analysis-examples-with-srvyr-27"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html"><i class="fa fa-check"></i>Rapid Surveys System (RSS)</a>
<ul>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#download-import-preparation-42"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#save-locally-41"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#survey-design-definition-33"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#variable-recoding-41"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#analysis-examples-with-the-survey-library-33"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#unweighted-counts-41"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#weighted-counts-33"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#descriptive-statistics-41"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#subsetting-41"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#measures-of-uncertainty-41"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#regression-models-and-tests-of-association-41"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#replication-example-39"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="rapid-surveys-system-rss.html"><a href="rapid-surveys-system-rss.html#analysis-examples-with-srvyr-28"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html"><i class="fa fa-check"></i>Survey of Business Owners (SBO)</a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#function-definitions-10"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#download-import-preparation-43"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#save-locally-42"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#survey-design-definition-34"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#variable-recoding-42"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#analysis-examples-with-the-survey-library-34"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#unweighted-counts-42"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#weighted-counts-34"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#descriptive-statistics-42"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#subsetting-42"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#measures-of-uncertainty-42"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#regression-models-and-tests-of-association-42"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-business-owners-sbo.html"><a href="survey-of-business-owners-sbo.html#replication-example-40"><i class="fa fa-check"></i>Replication Example</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html"><i class="fa fa-check"></i>Survey of Consumer Finances (SCF)</a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#function-definitions-11"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#download-import-preparation-44"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#save-locally-43"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#survey-design-definition-35"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#variable-recoding-43"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#analysis-examples-with-the-survey-library-35"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#unweighted-counts-43"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#weighted-counts-35"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#descriptive-statistics-43"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#subsetting-43"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#measures-of-uncertainty-43"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#regression-models-and-tests-of-association-43"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#replication-example-41"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="survey-of-consumer-finances-scf.html"><a href="survey-of-consumer-finances-scf.html#poverty-and-inequality-estimation-with-convey-4"><i class="fa fa-check"></i>Poverty and Inequality Estimation with <code>convey</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html"><i class="fa fa-check"></i>Survey of Income and Program Participation (SIPP)</a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#download-import-preparation-45"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#save-locally-44"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#survey-design-definition-36"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#variable-recoding-44"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#analysis-examples-with-the-survey-library-36"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#unweighted-counts-44"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#weighted-counts-36"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#descriptive-statistics-44"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#subsetting-44"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#measures-of-uncertainty-44"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#regression-models-and-tests-of-association-44"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#replication-example-42"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#poverty-and-inequality-estimation-with-convey-5"><i class="fa fa-check"></i>Poverty and Inequality Estimation with <code>convey</code>  </a></li>
<li class="chapter" data-level="" data-path="survey-of-income-and-program-participation-sipp.html"><a href="survey-of-income-and-program-participation-sipp.html#analysis-examples-with-srvyr-29"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html"><i class="fa fa-check"></i>Social Security Public-Use Data Files (SSA)</a>
<ul>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#download-import-preparation-46"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#save-locally-45"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#variable-recoding-45"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#analysis-examples-with-base-r-8"><i class="fa fa-check"></i>Analysis Examples with base R  </a>
<ul>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#unweighted-counts-45"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#descriptive-statistics-45"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#subsetting-45"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#measures-of-uncertainty-45"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#regression-models-and-tests-of-association-45"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#replication-example-43"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#analysis-examples-with-dplyr-8"><i class="fa fa-check"></i>Analysis Examples with <code>dplyr</code>  </a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#analysis-examples-with-data.table-8"><i class="fa fa-check"></i>Analysis Examples with <code>data.table</code>  </a></li>
<li class="chapter" data-level="" data-path="social-security-public-use-data-files-ssa.html"><a href="social-security-public-use-data-files-ssa.html#analysis-examples-with-duckdb-8"><i class="fa fa-check"></i>Analysis Examples with <code>duckdb</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html"><i class="fa fa-check"></i>Trends in International Mathematics and Science Study (TIMSS)</a>
<ul>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#function-definitions-12"><i class="fa fa-check"></i>Function Definitions</a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#download-import-preparation-47"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#save-locally-46"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#survey-design-definition-37"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#variable-recoding-46"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#analysis-examples-with-the-survey-library-37"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#unweighted-counts-46"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#weighted-counts-37"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#descriptive-statistics-46"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#subsetting-46"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#measures-of-uncertainty-46"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#regression-models-and-tests-of-association-46"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="trends-in-international-mathematics-and-science-study-timss.html"><a href="trends-in-international-mathematics-and-science-study-timss.html#replication-example-44"><i class="fa fa-check"></i>Replication Example</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html"><i class="fa fa-check"></i>Violence Against Children And Youth Surveys (VACS)</a>
<ul>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#download-import-preparation-48"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#save-locally-47"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#survey-design-definition-38"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#variable-recoding-47"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#analysis-examples-with-the-survey-library-38"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#unweighted-counts-47"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#weighted-counts-38"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#descriptive-statistics-47"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#subsetting-47"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#measures-of-uncertainty-47"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#regression-models-and-tests-of-association-47"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#replication-example-45"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="violence-against-children-and-youth-surveys-vacs.html"><a href="violence-against-children-and-youth-surveys-vacs.html#analysis-examples-with-srvyr-30"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html"><i class="fa fa-check"></i>Youth Risk Behavior Surveillance System (YRBSS)</a>
<ul>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#download-import-preparation-49"><i class="fa fa-check"></i>Download, Import, Preparation</a>
<ul>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#save-locally-48"><i class="fa fa-check"></i>Save Locally  </a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#survey-design-definition-39"><i class="fa fa-check"></i>Survey Design Definition</a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#variable-recoding-48"><i class="fa fa-check"></i>Variable Recoding</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#analysis-examples-with-the-survey-library-39"><i class="fa fa-check"></i>Analysis Examples with the <code>survey</code> library  </a>
<ul>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#unweighted-counts-48"><i class="fa fa-check"></i>Unweighted Counts</a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#weighted-counts-39"><i class="fa fa-check"></i>Weighted Counts</a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#descriptive-statistics-48"><i class="fa fa-check"></i>Descriptive Statistics</a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#subsetting-48"><i class="fa fa-check"></i>Subsetting</a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#measures-of-uncertainty-48"><i class="fa fa-check"></i>Measures of Uncertainty</a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#regression-models-and-tests-of-association-48"><i class="fa fa-check"></i>Regression Models and Tests of Association</a></li>
</ul></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#replication-example-46"><i class="fa fa-check"></i>Replication Example</a></li>
<li class="chapter" data-level="" data-path="youth-risk-behavior-surveillance-system-yrbss.html"><a href="youth-risk-behavior-surveillance-system-yrbss.html#analysis-examples-with-srvyr-31"><i class="fa fa-check"></i>Analysis Examples with <code>srvyr</code>  </a></li>
</ul></li>
<li class="divider"></li>
<li><a href="https://github.com/rstudio/bookdown" target="blank">Published with bookdown</a></li>

</ul>

      </nav>
    </div>

    <div class="book-body">
      <div class="body-inner">
        <div class="book-header" role="navigation">
          <h1>
            <i class="fa fa-circle-o-notch fa-spin"></i><a href="./">Analyze Survey Data for Free</a>
          </h1>
        </div>

        <div class="page-wrapper" tabindex="-1" role="main">
          <div class="page-inner">

            <section class="normal" id="section-">
<div id="progress-in-international-reading-literacy-study-pirls" class="section level1 unnumbered hasAnchor">
<h1>Progress in International Reading Literacy Study (PIRLS)<a href="progress-in-international-reading-literacy-study-pirls.html#progress-in-international-reading-literacy-study-pirls" class="anchor-section" aria-label="Anchor link to header"></a></h1>
<p><a href="https://www.gnu.org/licenses/gpl-3.0"><img src="https://img.shields.io/badge/License-GPLv3-blue.svg" alt="License: GPL v3" /></a> <a href="https://github.com/asdfree/pirls/actions"><img src="https://github.com/asdfree/pirls/actions/workflows/r.yml/badge.svg" alt="Github Actions Badge"></a></p>
<p>A comparative study of student achievement in reading and literacy across more than 50 nations.</p>
<ul>
<li><p>Grade-specific tables with one record per school, student, teacher, plus files containing student achievement, home background, student-teacher linkage, and within-country scoring reliability.</p></li>
<li><p>A complex survey generalizing to fourth-grade populations of participating countries.</p></li>
<li><p>Released quinquennially since 2001.</p></li>
<li><p>Funded by the <a href="https://www.iea.nl/">International Association for the Evaluation of Educational Achievement</a>, run at <a href="http://www.bc.edu/bc-web/schools/lsoe.html">BC</a>.</p></li>
</ul>
<hr />
<p>Please skim before you begin:</p>
<ol style="list-style-type: decimal">
<li><p><a href="https://pirls2021.org/data/downloads/P21_UG_International-Database.pdf">PIRLS 2021 User Guide for the International Database</a></p></li>
<li><p><a href="https://pirls2021.org/methods">Methods and Procedures: PIRLS 2021 Technical Report</a></p></li>
<li><p>A haiku regarding this microdata:</p></li>
</ol>
<div class="sourceCode" id="cb1044"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1044-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1044-1" tabindex="-1"></a><span class="co"># lascaux canary</span></span>
<span id="cb1044-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1044-2" tabindex="-1"></a><span class="co"># glyph jump reveal caged bard notes</span></span>
<span id="cb1044-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1044-3" tabindex="-1"></a><span class="co"># cryogenesis</span></span></code></pre></div>
<hr />
<div id="function-definitions-9" class="section level2 unnumbered hasAnchor">
<h2>Function Definitions<a href="progress-in-international-reading-literacy-study-pirls.html#function-definitions-9" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<p>This survey uses a multiply-imputed variance estimation technique described in <a href="https://pirls2021.org/methods/chapter-13">Methods Chapter 13</a>. Most users do not need to study this function carefully. Define a function specific to only this dataset:</p>
<div class="sourceCode" id="cb1045"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1045-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-1" tabindex="-1"></a>pirls_MIcombine <span class="ot">&lt;-</span></span>
<span id="cb1045-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-2" tabindex="-1"></a>    <span class="cf">function</span> (results, variances, <span class="at">call =</span> <span class="fu">sys.call</span>(), <span class="at">df.complete =</span> <span class="cn">Inf</span>, ...) {</span>
<span id="cb1045-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-3" tabindex="-1"></a>        m <span class="ot">&lt;-</span> <span class="fu">length</span>(results)</span>
<span id="cb1045-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-4" tabindex="-1"></a>        oldcall <span class="ot">&lt;-</span> <span class="fu">attr</span>(results, <span class="st">&quot;call&quot;</span>)</span>
<span id="cb1045-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-5" tabindex="-1"></a>        <span class="cf">if</span> (<span class="fu">missing</span>(variances)) {</span>
<span id="cb1045-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-6" tabindex="-1"></a>            variances <span class="ot">&lt;-</span> <span class="fu">suppressWarnings</span>(<span class="fu">lapply</span>(results, vcov))</span>
<span id="cb1045-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-7" tabindex="-1"></a>            results <span class="ot">&lt;-</span> <span class="fu">lapply</span>(results, coef)</span>
<span id="cb1045-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-8" tabindex="-1"></a>        }</span>
<span id="cb1045-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-9" tabindex="-1"></a>        vbar <span class="ot">&lt;-</span> variances[[<span class="dv">1</span>]]</span>
<span id="cb1045-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-10" tabindex="-1"></a>        cbar <span class="ot">&lt;-</span> results[[<span class="dv">1</span>]]</span>
<span id="cb1045-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-11" tabindex="-1"></a>        <span class="cf">for</span> (i <span class="cf">in</span> <span class="dv">2</span><span class="sc">:</span>m) {</span>
<span id="cb1045-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-12" tabindex="-1"></a>            cbar <span class="ot">&lt;-</span> cbar <span class="sc">+</span> results[[i]]</span>
<span id="cb1045-13"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-13" tabindex="-1"></a>            vbar <span class="ot">&lt;-</span> vbar <span class="sc">+</span> variances[[i]]</span>
<span id="cb1045-14"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-14" tabindex="-1"></a>        }</span>
<span id="cb1045-15"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-15" tabindex="-1"></a>        cbar <span class="ot">&lt;-</span> cbar<span class="sc">/</span>m</span>
<span id="cb1045-16"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-16" tabindex="-1"></a>        vbar <span class="ot">&lt;-</span> vbar<span class="sc">/</span>m</span>
<span id="cb1045-17"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-17" tabindex="-1"></a></span>
<span id="cb1045-18"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-18" tabindex="-1"></a>        <span class="co"># MODIFICATION</span></span>
<span id="cb1045-19"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-19" tabindex="-1"></a>        <span class="co"># evar &lt;- var(do.call(&quot;rbind&quot;, results))</span></span>
<span id="cb1045-20"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-20" tabindex="-1"></a>        evar <span class="ot">&lt;-</span> <span class="fu">sum</span>( ( <span class="fu">unlist</span>( results ) <span class="sc">-</span> cbar )<span class="sc">^</span><span class="dv">2</span> <span class="sc">/</span> <span class="dv">4</span> )</span>
<span id="cb1045-21"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-21" tabindex="-1"></a></span>
<span id="cb1045-22"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-22" tabindex="-1"></a>        </span>
<span id="cb1045-23"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-23" tabindex="-1"></a>        r <span class="ot">&lt;-</span> (<span class="dv">1</span> <span class="sc">+</span> <span class="dv">1</span><span class="sc">/</span>m) <span class="sc">*</span> evar<span class="sc">/</span>vbar</span>
<span id="cb1045-24"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-24" tabindex="-1"></a>        df <span class="ot">&lt;-</span> (m <span class="sc">-</span> <span class="dv">1</span>) <span class="sc">*</span> (<span class="dv">1</span> <span class="sc">+</span> <span class="dv">1</span><span class="sc">/</span>r)<span class="sc">^</span><span class="dv">2</span></span>
<span id="cb1045-25"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-25" tabindex="-1"></a>        <span class="cf">if</span> (<span class="fu">is.matrix</span>(df)) df <span class="ot">&lt;-</span> <span class="fu">diag</span>(df)</span>
<span id="cb1045-26"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-26" tabindex="-1"></a>        <span class="cf">if</span> (<span class="fu">is.finite</span>(df.complete)) {</span>
<span id="cb1045-27"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-27" tabindex="-1"></a>            dfobs <span class="ot">&lt;-</span> ((df.complete <span class="sc">+</span> <span class="dv">1</span>)<span class="sc">/</span>(df.complete <span class="sc">+</span> <span class="dv">3</span>)) <span class="sc">*</span> df.complete <span class="sc">*</span></span>
<span id="cb1045-28"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-28" tabindex="-1"></a>            vbar<span class="sc">/</span>(vbar <span class="sc">+</span> evar)</span>
<span id="cb1045-29"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-29" tabindex="-1"></a>            <span class="cf">if</span> (<span class="fu">is.matrix</span>(dfobs)) dfobs <span class="ot">&lt;-</span> <span class="fu">diag</span>(dfobs)</span>
<span id="cb1045-30"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-30" tabindex="-1"></a>            df <span class="ot">&lt;-</span> <span class="dv">1</span><span class="sc">/</span>(<span class="dv">1</span><span class="sc">/</span>dfobs <span class="sc">+</span> <span class="dv">1</span><span class="sc">/</span>df)</span>
<span id="cb1045-31"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-31" tabindex="-1"></a>        }</span>
<span id="cb1045-32"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-32" tabindex="-1"></a>        <span class="cf">if</span> (<span class="fu">is.matrix</span>(r)) r <span class="ot">&lt;-</span> <span class="fu">diag</span>(r)</span>
<span id="cb1045-33"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-33" tabindex="-1"></a>        rval <span class="ot">&lt;-</span> <span class="fu">list</span>(<span class="at">coefficients =</span> cbar, <span class="at">variance =</span> vbar <span class="sc">+</span> evar <span class="sc">*</span></span>
<span id="cb1045-34"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-34" tabindex="-1"></a>        (m <span class="sc">+</span> <span class="dv">1</span>)<span class="sc">/</span>m, <span class="at">call =</span> <span class="fu">c</span>(oldcall, call), <span class="at">nimp =</span> m, <span class="at">df =</span> df,</span>
<span id="cb1045-35"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-35" tabindex="-1"></a>        <span class="at">missinfo =</span> (r <span class="sc">+</span> <span class="dv">2</span><span class="sc">/</span>(df <span class="sc">+</span> <span class="dv">3</span>))<span class="sc">/</span>(r <span class="sc">+</span> <span class="dv">1</span>))</span>
<span id="cb1045-36"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-36" tabindex="-1"></a>        <span class="fu">class</span>(rval) <span class="ot">&lt;-</span> <span class="st">&quot;MIresult&quot;</span></span>
<span id="cb1045-37"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-37" tabindex="-1"></a>        rval</span>
<span id="cb1045-38"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1045-38" tabindex="-1"></a>    }</span></code></pre></div>
<hr />
</div>
<div id="download-import-preparation-36" class="section level2 unnumbered hasAnchor">
<h2>Download, Import, Preparation<a href="progress-in-international-reading-literacy-study-pirls.html#download-import-preparation-36" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<p>Download and unzip the 2021 fourth grade international database:</p>
<div class="sourceCode" id="cb1046"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1046-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-1" tabindex="-1"></a><span class="fu">library</span>(httr)</span>
<span id="cb1046-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-2" tabindex="-1"></a></span>
<span id="cb1046-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-3" tabindex="-1"></a>tf <span class="ot">&lt;-</span> <span class="fu">tempfile</span>()</span>
<span id="cb1046-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-4" tabindex="-1"></a></span>
<span id="cb1046-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-5" tabindex="-1"></a>this_url <span class="ot">&lt;-</span> <span class="st">&quot;https://pirls2021.org/data/downloads/P21_Data_R.zip&quot;</span></span>
<span id="cb1046-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-6" tabindex="-1"></a></span>
<span id="cb1046-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-7" tabindex="-1"></a><span class="fu">GET</span>( this_url , <span class="fu">write_disk</span>( tf ) , <span class="fu">progress</span>() )</span>
<span id="cb1046-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-8" tabindex="-1"></a></span>
<span id="cb1046-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1046-9" tabindex="-1"></a>unzipped_files <span class="ot">&lt;-</span> <span class="fu">unzip</span>( tf , <span class="at">exdir =</span> <span class="fu">tempdir</span>() )</span></code></pre></div>
<p>Import and stack each of the student context data files for <strong>Abu Dhabi through Bulgaria</strong>:</p>
<div class="sourceCode" id="cb1047"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1047-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-1" tabindex="-1"></a><span class="fu">library</span>(haven)</span>
<span id="cb1047-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-2" tabindex="-1"></a></span>
<span id="cb1047-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-3" tabindex="-1"></a><span class="co"># limit unzipped files to those starting with `asg` followed by three letters followed by `r5`</span></span>
<span id="cb1047-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-4" tabindex="-1"></a>asg_fns <span class="ot">&lt;-</span></span>
<span id="cb1047-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-5" tabindex="-1"></a>    unzipped_files[ </span>
<span id="cb1047-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-6" tabindex="-1"></a>        <span class="fu">grepl</span>( </span>
<span id="cb1047-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-7" tabindex="-1"></a>            <span class="st">&#39;^asg[a-z][a-z][a-z]r5&#39;</span> , </span>
<span id="cb1047-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-8" tabindex="-1"></a>            <span class="fu">basename</span>( unzipped_files ) , </span>
<span id="cb1047-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-9" tabindex="-1"></a>            <span class="at">ignore.case =</span> <span class="cn">TRUE</span> </span>
<span id="cb1047-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-10" tabindex="-1"></a>        ) </span>
<span id="cb1047-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-11" tabindex="-1"></a>    ]</span>
<span id="cb1047-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-12" tabindex="-1"></a></span>
<span id="cb1047-13"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-13" tabindex="-1"></a><span class="co"># further limit asg files to the first ten countries</span></span>
<span id="cb1047-14"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-14" tabindex="-1"></a>countries_thru_bulgaria <span class="ot">&lt;-</span></span>
<span id="cb1047-15"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-15" tabindex="-1"></a>    <span class="fu">c</span>(<span class="st">&quot;aad&quot;</span>, <span class="st">&quot;adu&quot;</span>, <span class="st">&quot;alb&quot;</span>, <span class="st">&quot;are&quot;</span>, <span class="st">&quot;aus&quot;</span>, <span class="st">&quot;aut&quot;</span>, <span class="st">&quot;aze&quot;</span>, <span class="st">&quot;bfl&quot;</span>, <span class="st">&quot;bfr&quot;</span>, <span class="st">&quot;bgr&quot;</span>)</span>
<span id="cb1047-16"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-16" tabindex="-1"></a></span>
<span id="cb1047-17"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-17" tabindex="-1"></a>fns_thru_bulgaria <span class="ot">&lt;-</span></span>
<span id="cb1047-18"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-18" tabindex="-1"></a>    <span class="fu">paste0</span>( <span class="fu">paste0</span>( <span class="st">&#39;^asg&#39;</span> , countries_thru_bulgaria , <span class="st">&#39;r5&#39;</span> ) , <span class="at">collapse =</span> <span class="st">&quot;|&quot;</span> )</span>
<span id="cb1047-19"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-19" tabindex="-1"></a></span>
<span id="cb1047-20"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-20" tabindex="-1"></a>asg_aad_bgr_fns <span class="ot">&lt;-</span></span>
<span id="cb1047-21"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-21" tabindex="-1"></a>    asg_fns[ <span class="fu">grepl</span>( fns_thru_bulgaria , <span class="fu">basename</span>( asg_fns ) , <span class="at">ignore.case =</span> <span class="cn">TRUE</span> ) ]</span>
<span id="cb1047-22"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-22" tabindex="-1"></a></span>
<span id="cb1047-23"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-23" tabindex="-1"></a>pirls_df <span class="ot">&lt;-</span> <span class="cn">NULL</span></span>
<span id="cb1047-24"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-24" tabindex="-1"></a></span>
<span id="cb1047-25"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-25" tabindex="-1"></a><span class="cf">for</span>( rdata_fn <span class="cf">in</span> asg_aad_bgr_fns ){</span>
<span id="cb1047-26"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-26" tabindex="-1"></a></span>
<span id="cb1047-27"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-27" tabindex="-1"></a>    this_tbl_name <span class="ot">&lt;-</span> <span class="fu">load</span>( rdata_fn )</span>
<span id="cb1047-28"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-28" tabindex="-1"></a>    </span>
<span id="cb1047-29"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-29" tabindex="-1"></a>    this_tbl <span class="ot">&lt;-</span> <span class="fu">get</span>( this_tbl_name ) ; <span class="fu">rm</span>( this_tbl_name )</span>
<span id="cb1047-30"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-30" tabindex="-1"></a>    </span>
<span id="cb1047-31"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-31" tabindex="-1"></a>    this_tbl <span class="ot">&lt;-</span> <span class="fu">zap_labels</span>( this_tbl )</span>
<span id="cb1047-32"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-32" tabindex="-1"></a>    </span>
<span id="cb1047-33"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-33" tabindex="-1"></a>    this_df <span class="ot">&lt;-</span> <span class="fu">data.frame</span>( this_tbl )</span>
<span id="cb1047-34"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-34" tabindex="-1"></a>    </span>
<span id="cb1047-35"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-35" tabindex="-1"></a>    <span class="fu">names</span>( this_df ) <span class="ot">&lt;-</span> <span class="fu">tolower</span>( <span class="fu">names</span>( this_df ) )</span>
<span id="cb1047-36"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-36" tabindex="-1"></a>    </span>
<span id="cb1047-37"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-37" tabindex="-1"></a>    pirls_df <span class="ot">&lt;-</span> <span class="fu">rbind</span>( pirls_df , this_df )</span>
<span id="cb1047-38"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-38" tabindex="-1"></a>    </span>
<span id="cb1047-39"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-39" tabindex="-1"></a>}</span>
<span id="cb1047-40"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-40" tabindex="-1"></a></span>
<span id="cb1047-41"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-41" tabindex="-1"></a><span class="co"># order the data.frame by unique student id</span></span>
<span id="cb1047-42"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1047-42" tabindex="-1"></a>pirls_df <span class="ot">&lt;-</span> pirls_df[ <span class="fu">with</span>( pirls_df , <span class="fu">order</span>( idcntry , idstud ) ) , ]</span></code></pre></div>
<div id="save-locally-35" class="section level3 unnumbered hasAnchor">
<h3>Save Locally  <a href="progress-in-international-reading-literacy-study-pirls.html#save-locally-35" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Save the object at any point:</p>
<div class="sourceCode" id="cb1048"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1048-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1048-1" tabindex="-1"></a><span class="co"># pirls_fn &lt;- file.path( path.expand( &quot;~&quot; ) , &quot;PIRLS&quot; , &quot;this_file.rds&quot; )</span></span>
<span id="cb1048-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1048-2" tabindex="-1"></a><span class="co"># saveRDS( pirls_df , file = pirls_fn , compress = FALSE )</span></span></code></pre></div>
<p>Load the same object:</p>
<div class="sourceCode" id="cb1049"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1049-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1049-1" tabindex="-1"></a><span class="co"># pirls_df &lt;- readRDS( pirls_fn )</span></span></code></pre></div>
</div>
<div id="survey-design-definition-28" class="section level3 unnumbered hasAnchor">
<h3>Survey Design Definition<a href="progress-in-international-reading-literacy-study-pirls.html#survey-design-definition-28" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Construct a multiply-imputed, complex sample survey design:</p>
<p>From among possibly plausible values, determine all columns that are multiply-imputed plausible values:</p>
<div class="sourceCode" id="cb1050"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1050-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-1" tabindex="-1"></a><span class="co"># identify all columns ending with `01` thru `05`</span></span>
<span id="cb1050-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-2" tabindex="-1"></a>ppv <span class="ot">&lt;-</span> <span class="fu">grep</span>( <span class="st">&quot;(.*)0[1-5]$&quot;</span> , <span class="fu">names</span>( pirls_df ) , <span class="at">value =</span> <span class="cn">TRUE</span> )</span>
<span id="cb1050-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-3" tabindex="-1"></a></span>
<span id="cb1050-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-4" tabindex="-1"></a><span class="co"># remove those ending digits</span></span>
<span id="cb1050-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-5" tabindex="-1"></a>ppv_prefix <span class="ot">&lt;-</span> <span class="fu">gsub</span>( <span class="st">&quot;0[1-5]$&quot;</span> , <span class="st">&quot;&quot;</span> , ppv )</span>
<span id="cb1050-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-6" tabindex="-1"></a></span>
<span id="cb1050-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-7" tabindex="-1"></a><span class="co"># identify each of the possibilities with exactly five matches (five implicates)</span></span>
<span id="cb1050-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-8" tabindex="-1"></a>pv <span class="ot">&lt;-</span> <span class="fu">names</span>( <span class="fu">table</span>( ppv_prefix )[ <span class="fu">table</span>( ppv_prefix ) <span class="sc">==</span> <span class="dv">5</span> ] )</span>
<span id="cb1050-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-9" tabindex="-1"></a></span>
<span id="cb1050-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-10" tabindex="-1"></a><span class="co"># identify each of the `01` thru `05` plausible value columns</span></span>
<span id="cb1050-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-11" tabindex="-1"></a>pv_columns <span class="ot">&lt;-</span></span>
<span id="cb1050-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-12" tabindex="-1"></a>    <span class="fu">grep</span>( </span>
<span id="cb1050-13"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-13" tabindex="-1"></a>        <span class="fu">paste0</span>( <span class="st">&quot;^&quot;</span> , pv , <span class="st">&quot;0[1-5]$&quot;</span> , <span class="at">collapse =</span> <span class="st">&quot;|&quot;</span> ) , </span>
<span id="cb1050-14"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-14" tabindex="-1"></a>        <span class="fu">names</span>( pirls_df ) , </span>
<span id="cb1050-15"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-15" tabindex="-1"></a>        <span class="at">value =</span> <span class="cn">TRUE</span> </span>
<span id="cb1050-16"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1050-16" tabindex="-1"></a>    )</span></code></pre></div>
<p>Extract those multiply-imputed columns into a separate data.frame, then remove them from the source:</p>
<div class="sourceCode" id="cb1051"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1051-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1051-1" tabindex="-1"></a>pv_wide_df <span class="ot">&lt;-</span> pirls_df[ <span class="fu">c</span>( <span class="st">&#39;idcntry&#39;</span> , <span class="st">&#39;idstud&#39;</span> , pv_columns ) ]</span>
<span id="cb1051-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1051-2" tabindex="-1"></a></span>
<span id="cb1051-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1051-3" tabindex="-1"></a>pirls_df[ pv_columns ] <span class="ot">&lt;-</span> <span class="cn">NULL</span></span></code></pre></div>
<p>Reshape these columns from one record per student to one record per student per implicate:</p>
<div class="sourceCode" id="cb1052"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1052-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-1" tabindex="-1"></a>pv_long_df <span class="ot">&lt;-</span> </span>
<span id="cb1052-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-2" tabindex="-1"></a>    <span class="fu">reshape</span>( </span>
<span id="cb1052-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-3" tabindex="-1"></a>        pv_wide_df , </span>
<span id="cb1052-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-4" tabindex="-1"></a>        <span class="at">varying =</span> <span class="fu">lapply</span>( <span class="fu">paste0</span>( pv , <span class="st">&#39;0&#39;</span> ) , paste0 , <span class="dv">1</span><span class="sc">:</span><span class="dv">5</span> ) , </span>
<span id="cb1052-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-5" tabindex="-1"></a>        <span class="at">direction =</span> <span class="st">&#39;long&#39;</span> , </span>
<span id="cb1052-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-6" tabindex="-1"></a>        <span class="at">timevar =</span> <span class="st">&#39;implicate&#39;</span> , </span>
<span id="cb1052-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-7" tabindex="-1"></a>        <span class="at">idvar =</span> <span class="fu">c</span>( <span class="st">&#39;idcntry&#39;</span> , <span class="st">&#39;idstud&#39;</span> ) </span>
<span id="cb1052-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-8" tabindex="-1"></a>    )</span>
<span id="cb1052-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-9" tabindex="-1"></a></span>
<span id="cb1052-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1052-10" tabindex="-1"></a><span class="fu">names</span>( pv_long_df ) <span class="ot">&lt;-</span> <span class="fu">gsub</span>( <span class="st">&quot;01$&quot;</span> , <span class="st">&quot;&quot;</span> , <span class="fu">names</span>( pv_long_df ) )</span></code></pre></div>
<p>Merge the columns from the source data.frame onto the one record per student per implicate data.frame:</p>
<div class="sourceCode" id="cb1053"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1053-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1053-1" tabindex="-1"></a>pirls_long_df <span class="ot">&lt;-</span> <span class="fu">merge</span>( pirls_df , pv_long_df )</span>
<span id="cb1053-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1053-2" tabindex="-1"></a></span>
<span id="cb1053-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1053-3" tabindex="-1"></a>pirls_long_df <span class="ot">&lt;-</span> pirls_long_df[ <span class="fu">with</span>( pirls_long_df , <span class="fu">order</span>( idcntry , idstud ) ) , ]</span>
<span id="cb1053-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1053-4" tabindex="-1"></a></span>
<span id="cb1053-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1053-5" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">nrow</span>( pirls_long_df ) <span class="sc">==</span> <span class="fu">nrow</span>( pv_long_df ) )</span>
<span id="cb1053-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1053-6" tabindex="-1"></a></span>
<span id="cb1053-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1053-7" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">nrow</span>( pirls_long_df ) <span class="sc">/</span> <span class="dv">5</span> <span class="sc">==</span> <span class="fu">nrow</span>( pirls_df ) )</span></code></pre></div>
<p>Divide the five plausible value implicates into a list with five data.frames based on the implicate number:</p>
<div class="sourceCode" id="cb1054"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1054-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1054-1" tabindex="-1"></a>pirls_list <span class="ot">&lt;-</span> <span class="fu">split</span>( pirls_long_df , pirls_long_df[ , <span class="st">&#39;implicate&#39;</span> ] )</span></code></pre></div>
<p>Construct a replicate weights table following the estimation technique described in <a href="https://pirls2021.org/methods/chapter-13">Methods Chapter 13</a>:</p>
<div class="sourceCode" id="cb1055"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1055-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-1" tabindex="-1"></a>weights_df <span class="ot">&lt;-</span> pirls_df[ <span class="fu">c</span>( <span class="st">&#39;jkrep&#39;</span> , <span class="st">&#39;jkzone&#39;</span> ) ]</span>
<span id="cb1055-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-2" tabindex="-1"></a></span>
<span id="cb1055-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-3" tabindex="-1"></a><span class="cf">for</span>( j <span class="cf">in</span> <span class="dv">1</span><span class="sc">:</span><span class="dv">75</span> ){</span>
<span id="cb1055-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-4" tabindex="-1"></a>    <span class="cf">for</span>( i <span class="cf">in</span> <span class="dv">0</span><span class="sc">:</span><span class="dv">1</span> ){</span>
<span id="cb1055-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-5" tabindex="-1"></a>        weights_df[ weights_df[ , <span class="st">&#39;jkzone&#39;</span> ] <span class="sc">!=</span> j , <span class="fu">paste0</span>( <span class="st">&#39;rw&#39;</span> , i , j ) ] <span class="ot">&lt;-</span> <span class="dv">1</span></span>
<span id="cb1055-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-6" tabindex="-1"></a>        </span>
<span id="cb1055-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-7" tabindex="-1"></a>        weights_df[ weights_df[ , <span class="st">&#39;jkzone&#39;</span> ] <span class="sc">==</span> j , <span class="fu">paste0</span>( <span class="st">&#39;rw&#39;</span> , i , j ) ] <span class="ot">&lt;-</span> </span>
<span id="cb1055-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-8" tabindex="-1"></a>            <span class="dv">2</span> <span class="sc">*</span> ( weights_df[ weights_df[ , <span class="st">&#39;jkzone&#39;</span> ] <span class="sc">==</span> j , <span class="st">&#39;jkrep&#39;</span> ] <span class="sc">==</span> i )</span>
<span id="cb1055-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-9" tabindex="-1"></a>    }</span>
<span id="cb1055-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-10" tabindex="-1"></a>}</span>
<span id="cb1055-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-11" tabindex="-1"></a></span>
<span id="cb1055-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1055-12" tabindex="-1"></a>weights_df[ <span class="fu">c</span>( <span class="st">&#39;jkrep&#39;</span> , <span class="st">&#39;jkzone&#39;</span> ) ] <span class="ot">&lt;-</span> <span class="cn">NULL</span></span></code></pre></div>
<p>Define the design:</p>
<div class="sourceCode" id="cb1056"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1056-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-1" tabindex="-1"></a><span class="fu">library</span>(survey)</span>
<span id="cb1056-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-2" tabindex="-1"></a><span class="fu">library</span>(mitools)</span>
<span id="cb1056-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-3" tabindex="-1"></a></span>
<span id="cb1056-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-4" tabindex="-1"></a>pirls_design <span class="ot">&lt;-</span> </span>
<span id="cb1056-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-5" tabindex="-1"></a>    <span class="fu">svrepdesign</span>(</span>
<span id="cb1056-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-6" tabindex="-1"></a>        <span class="at">weights =</span> <span class="sc">~</span>totwgt ,</span>
<span id="cb1056-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-7" tabindex="-1"></a>        <span class="at">repweights =</span> weights_df , </span>
<span id="cb1056-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-8" tabindex="-1"></a>        <span class="at">data =</span> <span class="fu">imputationList</span>( pirls_list ) ,</span>
<span id="cb1056-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-9" tabindex="-1"></a>        <span class="at">type =</span> <span class="st">&quot;other&quot;</span> ,</span>
<span id="cb1056-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-10" tabindex="-1"></a>        <span class="at">scale =</span> <span class="fl">0.5</span> ,</span>
<span id="cb1056-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-11" tabindex="-1"></a>        <span class="at">rscales =</span> <span class="fu">rep</span>( <span class="dv">1</span> , <span class="dv">150</span> ) ,</span>
<span id="cb1056-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-12" tabindex="-1"></a>        <span class="at">combined.weights =</span> <span class="cn">FALSE</span> ,</span>
<span id="cb1056-13"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-13" tabindex="-1"></a>        <span class="at">mse =</span> <span class="cn">TRUE</span></span>
<span id="cb1056-14"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1056-14" tabindex="-1"></a>    )</span></code></pre></div>
</div>
<div id="variable-recoding-35" class="section level3 unnumbered hasAnchor">
<h3>Variable Recoding<a href="progress-in-international-reading-literacy-study-pirls.html#variable-recoding-35" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Add new columns to the data set:</p>
<div class="sourceCode" id="cb1057"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1057-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-1" tabindex="-1"></a>pirls_design <span class="ot">&lt;-</span> </span>
<span id="cb1057-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-2" tabindex="-1"></a>    <span class="fu">update</span>( </span>
<span id="cb1057-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-3" tabindex="-1"></a>        pirls_design , </span>
<span id="cb1057-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-4" tabindex="-1"></a>        </span>
<span id="cb1057-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-5" tabindex="-1"></a>        <span class="at">one =</span> <span class="dv">1</span> ,</span>
<span id="cb1057-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-6" tabindex="-1"></a>        </span>
<span id="cb1057-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-7" tabindex="-1"></a>        <span class="at">countries_thru_bulgaria =</span> </span>
<span id="cb1057-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-8" tabindex="-1"></a>        </span>
<span id="cb1057-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-9" tabindex="-1"></a>            <span class="fu">factor</span>( </span>
<span id="cb1057-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-10" tabindex="-1"></a>            </span>
<span id="cb1057-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-11" tabindex="-1"></a>                <span class="fu">as.numeric</span>( idcntry ) ,</span>
<span id="cb1057-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-12" tabindex="-1"></a>                </span>
<span id="cb1057-13"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-13" tabindex="-1"></a>                <span class="at">levels =</span> <span class="fu">c</span>(7842L, 7841L, 8L, 784L, 36L, 40L, 31L, 956L, 957L, 100L) ,</span>
<span id="cb1057-14"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-14" tabindex="-1"></a></span>
<span id="cb1057-15"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-15" tabindex="-1"></a>                <span class="at">labels =</span></span>
<span id="cb1057-16"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-16" tabindex="-1"></a>                    <span class="fu">c</span>(<span class="st">&quot;Abu Dhabi, UAE&quot;</span>, <span class="st">&quot;Dubai, UAE&quot;</span>, <span class="st">&quot;Albania&quot;</span>, <span class="st">&quot;UAE&quot;</span>, <span class="st">&quot;Australia&quot;</span>, <span class="st">&quot;Austria&quot;</span>,</span>
<span id="cb1057-17"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-17" tabindex="-1"></a>                    <span class="st">&quot;Azerbaijan&quot;</span>, <span class="st">&quot;Belgium (Flemish)&quot;</span>, <span class="st">&quot;Belgium (French)&quot;</span>,<span class="st">&quot;Bulgaria&quot;</span>)</span>
<span id="cb1057-18"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-18" tabindex="-1"></a>                </span>
<span id="cb1057-19"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-19" tabindex="-1"></a>            ) ,</span>
<span id="cb1057-20"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-20" tabindex="-1"></a>        </span>
<span id="cb1057-21"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-21" tabindex="-1"></a>        <span class="at">sex =</span> <span class="fu">factor</span>( itsex , <span class="at">levels =</span> <span class="dv">1</span><span class="sc">:</span><span class="dv">2</span> , <span class="at">labels =</span> <span class="fu">c</span>( <span class="st">&quot;female&quot;</span> , <span class="st">&quot;male&quot;</span> ) ) ,</span>
<span id="cb1057-22"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-22" tabindex="-1"></a>        </span>
<span id="cb1057-23"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-23" tabindex="-1"></a>        <span class="at">always_speak_language_of_test_at_home =</span></span>
<span id="cb1057-24"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-24" tabindex="-1"></a>            <span class="fu">ifelse</span>( asbg03 <span class="sc">%in%</span> <span class="dv">1</span><span class="sc">:</span><span class="dv">4</span> , <span class="fu">as.numeric</span>( asbg03 <span class="sc">==</span> <span class="dv">1</span> ) , <span class="cn">NA</span> )</span>
<span id="cb1057-25"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-25" tabindex="-1"></a></span>
<span id="cb1057-26"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1057-26" tabindex="-1"></a>    )</span></code></pre></div>
<hr />
</div>
</div>
<div id="analysis-examples-with-the-survey-library-28" class="section level2 unnumbered hasAnchor">
<h2>Analysis Examples with the <code>survey</code> library  <a href="progress-in-international-reading-literacy-study-pirls.html#analysis-examples-with-the-survey-library-28" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<div id="unweighted-counts-35" class="section level3 unnumbered hasAnchor">
<h3>Unweighted Counts<a href="progress-in-international-reading-literacy-study-pirls.html#unweighted-counts-35" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Count the unweighted number of records in the survey sample, overall and by groups:</p>
<div class="sourceCode" id="cb1058"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1058-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1058-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svyby</span>( <span class="sc">~</span> one , <span class="sc">~</span> one , unwtd.count ) ) )</span>
<span id="cb1058-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1058-2" tabindex="-1"></a></span>
<span id="cb1058-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1058-3" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svyby</span>( <span class="sc">~</span> one , <span class="sc">~</span> sex , unwtd.count ) ) )</span></code></pre></div>
</div>
<div id="weighted-counts-28" class="section level3 unnumbered hasAnchor">
<h3>Weighted Counts<a href="progress-in-international-reading-literacy-study-pirls.html#weighted-counts-28" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Count the weighted size of the generalizable population, overall and by groups:</p>
<div class="sourceCode" id="cb1059"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1059-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1059-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svytotal</span>( <span class="sc">~</span> one ) ) )</span>
<span id="cb1059-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1059-2" tabindex="-1"></a></span>
<span id="cb1059-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1059-3" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1059-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1059-4" tabindex="-1"></a>    <span class="fu">svyby</span>( <span class="sc">~</span> one , <span class="sc">~</span> sex , svytotal )</span>
<span id="cb1059-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1059-5" tabindex="-1"></a>) )</span></code></pre></div>
</div>
<div id="descriptive-statistics-35" class="section level3 unnumbered hasAnchor">
<h3>Descriptive Statistics<a href="progress-in-international-reading-literacy-study-pirls.html#descriptive-statistics-35" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Calculate the mean (average) of a linear variable, overall and by groups:</p>
<div class="sourceCode" id="cb1060"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1060-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1060-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svymean</span>( <span class="sc">~</span> asrrea , <span class="at">na.rm =</span> <span class="cn">TRUE</span> ) ) )</span>
<span id="cb1060-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1060-2" tabindex="-1"></a></span>
<span id="cb1060-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1060-3" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1060-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1060-4" tabindex="-1"></a>    <span class="fu">svyby</span>( <span class="sc">~</span> asrrea , <span class="sc">~</span> sex , svymean , <span class="at">na.rm =</span> <span class="cn">TRUE</span> )</span>
<span id="cb1060-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1060-5" tabindex="-1"></a>) )</span></code></pre></div>
<p>Calculate the distribution of a categorical variable, overall and by groups:</p>
<div class="sourceCode" id="cb1061"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1061-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1061-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svymean</span>( <span class="sc">~</span> countries_thru_bulgaria ) ) )</span>
<span id="cb1061-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1061-2" tabindex="-1"></a></span>
<span id="cb1061-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1061-3" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1061-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1061-4" tabindex="-1"></a>    <span class="fu">svyby</span>( <span class="sc">~</span> countries_thru_bulgaria , <span class="sc">~</span> sex , svymean )</span>
<span id="cb1061-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1061-5" tabindex="-1"></a>) )</span></code></pre></div>
<p>Calculate the sum of a linear variable, overall and by groups:</p>
<div class="sourceCode" id="cb1062"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1062-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1062-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svytotal</span>( <span class="sc">~</span> asrrea , <span class="at">na.rm =</span> <span class="cn">TRUE</span> ) ) )</span>
<span id="cb1062-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1062-2" tabindex="-1"></a></span>
<span id="cb1062-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1062-3" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1062-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1062-4" tabindex="-1"></a>    <span class="fu">svyby</span>( <span class="sc">~</span> asrrea , <span class="sc">~</span> sex , svytotal , <span class="at">na.rm =</span> <span class="cn">TRUE</span> )</span>
<span id="cb1062-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1062-5" tabindex="-1"></a>) )</span></code></pre></div>
<p>Calculate the weighted sum of a categorical variable, overall and by groups:</p>
<div class="sourceCode" id="cb1063"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1063-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1063-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svytotal</span>( <span class="sc">~</span> countries_thru_bulgaria ) ) )</span>
<span id="cb1063-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1063-2" tabindex="-1"></a></span>
<span id="cb1063-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1063-3" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1063-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1063-4" tabindex="-1"></a>    <span class="fu">svyby</span>( <span class="sc">~</span> countries_thru_bulgaria , <span class="sc">~</span> sex , svytotal )</span>
<span id="cb1063-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1063-5" tabindex="-1"></a>) )</span></code></pre></div>
<p>Calculate the median (50th percentile) of a linear variable, overall and by groups:</p>
<div class="sourceCode" id="cb1064"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1064-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1064-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-2" tabindex="-1"></a>    <span class="fu">svyquantile</span>(</span>
<span id="cb1064-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-3" tabindex="-1"></a>        <span class="sc">~</span> asrrea ,</span>
<span id="cb1064-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-4" tabindex="-1"></a>        <span class="fl">0.5</span> , <span class="at">se =</span> <span class="cn">TRUE</span> , <span class="at">na.rm =</span> <span class="cn">TRUE</span> </span>
<span id="cb1064-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-5" tabindex="-1"></a>) ) )</span>
<span id="cb1064-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-6" tabindex="-1"></a></span>
<span id="cb1064-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-7" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1064-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-8" tabindex="-1"></a>    <span class="fu">svyby</span>(</span>
<span id="cb1064-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-9" tabindex="-1"></a>        <span class="sc">~</span> asrrea , <span class="sc">~</span> sex , svyquantile ,</span>
<span id="cb1064-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-10" tabindex="-1"></a>        <span class="fl">0.5</span> , <span class="at">se =</span> <span class="cn">TRUE</span> ,</span>
<span id="cb1064-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-11" tabindex="-1"></a>        <span class="at">ci =</span> <span class="cn">TRUE</span> , <span class="at">na.rm =</span> <span class="cn">TRUE</span></span>
<span id="cb1064-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1064-12" tabindex="-1"></a>) ) )</span></code></pre></div>
<p>Estimate a ratio:</p>
<div class="sourceCode" id="cb1065"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1065-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1065-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1065-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1065-2" tabindex="-1"></a>    <span class="fu">svyratio</span>( <span class="at">numerator =</span> <span class="sc">~</span> asrlit , <span class="at">denominator =</span> <span class="sc">~</span> asrrea )</span>
<span id="cb1065-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1065-3" tabindex="-1"></a>) )</span></code></pre></div>
</div>
<div id="subsetting-35" class="section level3 unnumbered hasAnchor">
<h3>Subsetting<a href="progress-in-international-reading-literacy-study-pirls.html#subsetting-35" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Restrict the survey design to Australia, Austria, Azerbaijan, Belgium (French):</p>
<div class="sourceCode" id="cb1066"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1066-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1066-1" tabindex="-1"></a>sub_pirls_design <span class="ot">&lt;-</span> <span class="fu">subset</span>( pirls_design , idcntry <span class="sc">%in%</span> <span class="fu">c</span>( <span class="dv">36</span> , <span class="dv">40</span> , <span class="dv">31</span> , <span class="dv">956</span> ) )</span></code></pre></div>
<p>Calculate the mean (average) of this subset:</p>
<div class="sourceCode" id="cb1067"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1067-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1067-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( sub_pirls_design , <span class="fu">svymean</span>( <span class="sc">~</span> asrrea , <span class="at">na.rm =</span> <span class="cn">TRUE</span> ) ) )</span></code></pre></div>
</div>
<div id="measures-of-uncertainty-35" class="section level3 unnumbered hasAnchor">
<h3>Measures of Uncertainty<a href="progress-in-international-reading-literacy-study-pirls.html#measures-of-uncertainty-35" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Extract the coefficient, standard error, confidence interval, and coefficient of variation from any descriptive statistics function result, overall and by groups:</p>
<div class="sourceCode" id="cb1068"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1068-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-1" tabindex="-1"></a>this_result <span class="ot">&lt;-</span></span>
<span id="cb1068-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-2" tabindex="-1"></a>    <span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1068-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-3" tabindex="-1"></a>        <span class="fu">svymean</span>( <span class="sc">~</span> asrrea , <span class="at">na.rm =</span> <span class="cn">TRUE</span> )</span>
<span id="cb1068-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-4" tabindex="-1"></a>    ) )</span>
<span id="cb1068-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-5" tabindex="-1"></a></span>
<span id="cb1068-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-6" tabindex="-1"></a><span class="fu">coef</span>( this_result )</span>
<span id="cb1068-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-7" tabindex="-1"></a><span class="fu">SE</span>( this_result )</span>
<span id="cb1068-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-8" tabindex="-1"></a><span class="fu">confint</span>( this_result )</span>
<span id="cb1068-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-9" tabindex="-1"></a><span class="fu">cv</span>( this_result )</span>
<span id="cb1068-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-10" tabindex="-1"></a></span>
<span id="cb1068-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-11" tabindex="-1"></a>grouped_result <span class="ot">&lt;-</span></span>
<span id="cb1068-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-12" tabindex="-1"></a>    <span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1068-13"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-13" tabindex="-1"></a>        <span class="fu">svyby</span>( <span class="sc">~</span> asrrea , <span class="sc">~</span> sex , svymean , <span class="at">na.rm =</span> <span class="cn">TRUE</span> )</span>
<span id="cb1068-14"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-14" tabindex="-1"></a>    ) )</span>
<span id="cb1068-15"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-15" tabindex="-1"></a></span>
<span id="cb1068-16"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-16" tabindex="-1"></a><span class="fu">coef</span>( grouped_result )</span>
<span id="cb1068-17"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-17" tabindex="-1"></a><span class="fu">SE</span>( grouped_result )</span>
<span id="cb1068-18"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-18" tabindex="-1"></a><span class="fu">confint</span>( grouped_result )</span>
<span id="cb1068-19"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1068-19" tabindex="-1"></a><span class="fu">cv</span>( grouped_result )</span></code></pre></div>
<p>Calculate the degrees of freedom of any survey design object:</p>
<div class="sourceCode" id="cb1069"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1069-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1069-1" tabindex="-1"></a><span class="fu">degf</span>( pirls_design<span class="sc">$</span>designs[[<span class="dv">1</span>]] )</span></code></pre></div>
<p>Calculate the complex sample survey-adjusted variance of any statistic:</p>
<div class="sourceCode" id="cb1070"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1070-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1070-1" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design , <span class="fu">svyvar</span>( <span class="sc">~</span> asrrea , <span class="at">na.rm =</span> <span class="cn">TRUE</span> ) ) )</span></code></pre></div>
<p>Include the complex sample design effect in the result for a specific statistic:</p>
<div class="sourceCode" id="cb1071"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1071-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-1" tabindex="-1"></a><span class="co"># SRS without replacement</span></span>
<span id="cb1071-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-2" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1071-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-3" tabindex="-1"></a>    <span class="fu">svymean</span>( <span class="sc">~</span> asrrea , <span class="at">na.rm =</span> <span class="cn">TRUE</span> , <span class="at">deff =</span> <span class="cn">TRUE</span> )</span>
<span id="cb1071-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-4" tabindex="-1"></a>) )</span>
<span id="cb1071-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-5" tabindex="-1"></a></span>
<span id="cb1071-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-6" tabindex="-1"></a><span class="co"># SRS with replacement</span></span>
<span id="cb1071-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-7" tabindex="-1"></a><span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1071-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-8" tabindex="-1"></a>    <span class="fu">svymean</span>( <span class="sc">~</span> asrrea , <span class="at">na.rm =</span> <span class="cn">TRUE</span> , <span class="at">deff =</span> <span class="st">&quot;replace&quot;</span> )</span>
<span id="cb1071-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1071-9" tabindex="-1"></a>) )</span></code></pre></div>
<p>Compute confidence intervals for proportions using methods that may be more accurate near 0 and 1. See <code>?svyciprop</code> for alternatives:</p>
<div class="sourceCode" id="cb1072"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1072-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1072-1" tabindex="-1"></a><span class="co"># MIsvyciprop( ~ always_speak_language_of_test_at_home , pirls_design ,</span></span>
<span id="cb1072-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1072-2" tabindex="-1"></a><span class="co">#   method = &quot;likelihood&quot; , na.rm = TRUE )</span></span></code></pre></div>
</div>
<div id="regression-models-and-tests-of-association-35" class="section level3 unnumbered hasAnchor">
<h3>Regression Models and Tests of Association<a href="progress-in-international-reading-literacy-study-pirls.html#regression-models-and-tests-of-association-35" class="anchor-section" aria-label="Anchor link to header"></a></h3>
<p>Perform a design-based t-test:</p>
<div class="sourceCode" id="cb1073"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1073-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1073-1" tabindex="-1"></a><span class="co"># MIsvyttest( asrrea ~ always_speak_language_of_test_at_home , pirls_design )</span></span></code></pre></div>
<p>Perform a chi-squared test of association for survey data:</p>
<div class="sourceCode" id="cb1074"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1074-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1074-1" tabindex="-1"></a><span class="co"># MIsvychisq( ~ always_speak_language_of_test_at_home + countries_thru_bulgaria , pirls_design )</span></span></code></pre></div>
<p>Perform a survey-weighted generalized linear model:</p>
<div class="sourceCode" id="cb1075"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1075-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1075-1" tabindex="-1"></a>glm_result <span class="ot">&lt;-</span> </span>
<span id="cb1075-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1075-2" tabindex="-1"></a>    <span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( pirls_design ,</span>
<span id="cb1075-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1075-3" tabindex="-1"></a>        <span class="fu">svyglm</span>( asrrea <span class="sc">~</span> always_speak_language_of_test_at_home <span class="sc">+</span> countries_thru_bulgaria )</span>
<span id="cb1075-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1075-4" tabindex="-1"></a>    ) )</span>
<span id="cb1075-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1075-5" tabindex="-1"></a>    </span>
<span id="cb1075-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1075-6" tabindex="-1"></a><span class="fu">summary</span>( glm_result )</span></code></pre></div>
<hr />
</div>
</div>
<div id="replication-example-33" class="section level2 unnumbered hasAnchor">
<h2>Replication Example<a href="progress-in-international-reading-literacy-study-pirls.html#replication-example-33" class="anchor-section" aria-label="Anchor link to header"></a></h2>
<p>This example matches the mean proficiency and standard error of the <code>Australia</code> row of the <code>Summary Statistics and Standard Errors for Proficiency in Overall Reading</code> table from the <a href="https://pirls2021.org/wp-content/uploads/2023/05/P21_MP_Ch13-standard-errors.pdf#page=12">Appendix 13A: Summary Statistics and Standard Errors for Proficiency in Reading</a>:</p>
<div class="sourceCode" id="cb1076"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1076-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-1" tabindex="-1"></a>australia_design <span class="ot">&lt;-</span> <span class="fu">subset</span>( pirls_design , countries_thru_bulgaria <span class="sc">%in%</span> <span class="st">&quot;Australia&quot;</span> )</span>
<span id="cb1076-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-2" tabindex="-1"></a></span>
<span id="cb1076-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-3" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">nrow</span>( australia_design ) <span class="sc">==</span> <span class="dv">5487</span> )</span>
<span id="cb1076-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-4" tabindex="-1"></a></span>
<span id="cb1076-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-5" tabindex="-1"></a>result <span class="ot">&lt;-</span> <span class="fu">pirls_MIcombine</span>( <span class="fu">with</span>( australia_design , <span class="fu">svymean</span>( <span class="sc">~</span> asrrea ) ) )</span>
<span id="cb1076-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-6" tabindex="-1"></a></span>
<span id="cb1076-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-7" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">round</span>( <span class="fu">coef</span>( result ) , <span class="dv">3</span> ) <span class="sc">==</span> <span class="fl">540.134</span> )</span>
<span id="cb1076-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-8" tabindex="-1"></a></span>
<span id="cb1076-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1076-9" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">round</span>( <span class="fu">SE</span>( result ) , <span class="dv">3</span> ) <span class="sc">==</span> <span class="fl">1.728</span> )</span></code></pre></div>
<p>This example matches the jackknife sampling, imputation, and total variances of the same row:</p>
<div class="sourceCode" id="cb1077"><pre class="sourceCode r"><code class="sourceCode r"><span id="cb1077-1"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-1" tabindex="-1"></a>australia_fn <span class="ot">&lt;-</span> unzipped_files[ <span class="fu">grepl</span>( <span class="st">&#39;ASGAUS&#39;</span> , <span class="fu">basename</span>( unzipped_files ) ) ]</span>
<span id="cb1077-2"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-2" tabindex="-1"></a>australia_tbl_name <span class="ot">&lt;-</span> <span class="fu">load</span>( australia_fn )</span>
<span id="cb1077-3"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-3" tabindex="-1"></a>australia_tbl <span class="ot">&lt;-</span> <span class="fu">get</span>( australia_tbl_name ) ; <span class="fu">rm</span>( australia_tbl_name )</span>
<span id="cb1077-4"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-4" tabindex="-1"></a>australia_tbl <span class="ot">&lt;-</span> <span class="fu">zap_labels</span>( australia_tbl )</span>
<span id="cb1077-5"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-5" tabindex="-1"></a>australia_df <span class="ot">&lt;-</span> <span class="fu">data.frame</span>( australia_tbl )</span>
<span id="cb1077-6"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-6" tabindex="-1"></a><span class="fu">names</span>( australia_df ) <span class="ot">&lt;-</span> <span class="fu">tolower</span>( <span class="fu">names</span>( australia_df ) )</span>
<span id="cb1077-7"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-7" tabindex="-1"></a></span>
<span id="cb1077-8"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-8" tabindex="-1"></a>estimate <span class="ot">&lt;-</span></span>
<span id="cb1077-9"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-9" tabindex="-1"></a>    <span class="fu">mean</span>( <span class="fu">c</span>(</span>
<span id="cb1077-10"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-10" tabindex="-1"></a>        <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea01 , totwgt ) ) ,</span>
<span id="cb1077-11"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-11" tabindex="-1"></a>        <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea02 , totwgt ) ) ,</span>
<span id="cb1077-12"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-12" tabindex="-1"></a>        <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea03 , totwgt ) ) ,</span>
<span id="cb1077-13"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-13" tabindex="-1"></a>        <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea04 , totwgt ) ) ,</span>
<span id="cb1077-14"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-14" tabindex="-1"></a>        <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea05 , totwgt ) )</span>
<span id="cb1077-15"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-15" tabindex="-1"></a>    ) )</span>
<span id="cb1077-16"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-16" tabindex="-1"></a></span>
<span id="cb1077-17"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-17" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">round</span>( estimate , <span class="dv">3</span> ) <span class="sc">==</span> <span class="fl">540.134</span> )</span>
<span id="cb1077-18"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-18" tabindex="-1"></a></span>
<span id="cb1077-19"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-19" tabindex="-1"></a><span class="cf">for</span>( k <span class="cf">in</span> <span class="dv">1</span><span class="sc">:</span><span class="dv">5</span> ){</span>
<span id="cb1077-20"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-20" tabindex="-1"></a></span>
<span id="cb1077-21"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-21" tabindex="-1"></a>    this_variance <span class="ot">&lt;-</span> <span class="dv">0</span></span>
<span id="cb1077-22"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-22" tabindex="-1"></a>    </span>
<span id="cb1077-23"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-23" tabindex="-1"></a>    <span class="cf">for</span>( j <span class="cf">in</span> <span class="dv">1</span><span class="sc">:</span><span class="dv">75</span> ){</span>
<span id="cb1077-24"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-24" tabindex="-1"></a>        <span class="cf">for</span>( i <span class="cf">in</span> <span class="dv">0</span><span class="sc">:</span><span class="dv">1</span> ){</span>
<span id="cb1077-25"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-25" tabindex="-1"></a>            this_variance <span class="ot">&lt;-</span> </span>
<span id="cb1077-26"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-26" tabindex="-1"></a>                this_variance <span class="sc">+</span> </span>
<span id="cb1077-27"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-27" tabindex="-1"></a>                ( </span>
<span id="cb1077-28"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-28" tabindex="-1"></a>                    <span class="fu">weighted.mean</span>( </span>
<span id="cb1077-29"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-29" tabindex="-1"></a>                        australia_df[ , <span class="fu">paste0</span>( <span class="st">&#39;asrrea0&#39;</span> , k ) ] , </span>
<span id="cb1077-30"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-30" tabindex="-1"></a>                        <span class="fu">ifelse</span>( </span>
<span id="cb1077-31"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-31" tabindex="-1"></a>                            j <span class="sc">==</span> australia_df[ , <span class="st">&#39;jkzone&#39;</span> ] , </span>
<span id="cb1077-32"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-32" tabindex="-1"></a>                            australia_df[ , <span class="st">&#39;totwgt&#39;</span> ] <span class="sc">*</span> <span class="dv">2</span> <span class="sc">*</span> ( australia_df[ , <span class="st">&#39;jkrep&#39;</span> ] <span class="sc">==</span> i ) , </span>
<span id="cb1077-33"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-33" tabindex="-1"></a>                            australia_df[ , <span class="st">&#39;totwgt&#39;</span> ] </span>
<span id="cb1077-34"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-34" tabindex="-1"></a>                        )</span>
<span id="cb1077-35"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-35" tabindex="-1"></a>                    ) <span class="sc">-</span></span>
<span id="cb1077-36"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-36" tabindex="-1"></a>                    <span class="fu">weighted.mean</span>( </span>
<span id="cb1077-37"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-37" tabindex="-1"></a>                        australia_df[ , <span class="fu">paste0</span>( <span class="st">&#39;asrrea0&#39;</span> , k ) ] , </span>
<span id="cb1077-38"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-38" tabindex="-1"></a>                        australia_df[ , <span class="st">&#39;totwgt&#39;</span> ]</span>
<span id="cb1077-39"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-39" tabindex="-1"></a>                    )</span>
<span id="cb1077-40"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-40" tabindex="-1"></a>                )<span class="sc">^</span><span class="dv">2</span></span>
<span id="cb1077-41"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-41" tabindex="-1"></a>        }</span>
<span id="cb1077-42"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-42" tabindex="-1"></a>    }</span>
<span id="cb1077-43"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-43" tabindex="-1"></a>    </span>
<span id="cb1077-44"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-44" tabindex="-1"></a>    <span class="fu">assign</span>( <span class="fu">paste0</span>( <span class="st">&#39;v&#39;</span> , k ) , this_variance <span class="sc">*</span> <span class="fl">0.5</span> )</span>
<span id="cb1077-45"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-45" tabindex="-1"></a></span>
<span id="cb1077-46"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-46" tabindex="-1"></a>}</span>
<span id="cb1077-47"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-47" tabindex="-1"></a></span>
<span id="cb1077-48"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-48" tabindex="-1"></a>sampling_variance <span class="ot">&lt;-</span> <span class="fu">mean</span>( <span class="fu">c</span>( v1 , v2 , v3 , v4 , v5 ) )</span>
<span id="cb1077-49"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-49" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">round</span>( sampling_variance , <span class="dv">3</span> ) <span class="sc">==</span> <span class="fl">2.653</span> )</span>
<span id="cb1077-50"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-50" tabindex="-1"></a></span>
<span id="cb1077-51"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-51" tabindex="-1"></a>imputation_variance <span class="ot">&lt;-</span></span>
<span id="cb1077-52"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-52" tabindex="-1"></a>    ( <span class="dv">6</span> <span class="sc">/</span> <span class="dv">5</span> ) <span class="sc">*</span> </span>
<span id="cb1077-53"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-53" tabindex="-1"></a>    ( </span>
<span id="cb1077-54"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-54" tabindex="-1"></a>        ( ( <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea01 , totwgt ) ) <span class="sc">-</span> estimate )<span class="sc">^</span><span class="dv">2</span> <span class="sc">/</span> <span class="dv">4</span> ) <span class="sc">+</span></span>
<span id="cb1077-55"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-55" tabindex="-1"></a>        ( ( <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea02 , totwgt ) ) <span class="sc">-</span> estimate )<span class="sc">^</span><span class="dv">2</span> <span class="sc">/</span> <span class="dv">4</span> ) <span class="sc">+</span></span>
<span id="cb1077-56"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-56" tabindex="-1"></a>        ( ( <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea03 , totwgt ) ) <span class="sc">-</span> estimate )<span class="sc">^</span><span class="dv">2</span> <span class="sc">/</span> <span class="dv">4</span> ) <span class="sc">+</span></span>
<span id="cb1077-57"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-57" tabindex="-1"></a>        ( ( <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea04 , totwgt ) ) <span class="sc">-</span> estimate )<span class="sc">^</span><span class="dv">2</span> <span class="sc">/</span> <span class="dv">4</span> ) <span class="sc">+</span></span>
<span id="cb1077-58"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-58" tabindex="-1"></a>        ( ( <span class="fu">with</span>( australia_df , <span class="fu">weighted.mean</span>( asrrea05 , totwgt ) ) <span class="sc">-</span> estimate )<span class="sc">^</span><span class="dv">2</span> <span class="sc">/</span> <span class="dv">4</span> ) </span>
<span id="cb1077-59"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-59" tabindex="-1"></a>    )</span>
<span id="cb1077-60"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-60" tabindex="-1"></a></span>
<span id="cb1077-61"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-61" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">round</span>( imputation_variance , <span class="dv">3</span> ) <span class="sc">==</span> <span class="fl">0.333</span> )</span>
<span id="cb1077-62"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-62" tabindex="-1"></a></span>
<span id="cb1077-63"><a href="progress-in-international-reading-literacy-study-pirls.html#cb1077-63" tabindex="-1"></a><span class="fu">stopifnot</span>( <span class="fu">round</span>( sampling_variance <span class="sc">+</span> imputation_variance , <span class="dv">3</span> ) <span class="sc">==</span> <span class="fl">2.987</span> )</span></code></pre></div>

</div>
</div>
            </section>

          </div>
        </div>
      </div>
<a href="programme-for-the-international-assessment-of-adult-competencies-piaac.html" class="navigation navigation-prev " aria-label="Previous page"><i class="fa fa-angle-left"></i></a>
<a href="public-libraries-survey-pls.html" class="navigation navigation-next " aria-label="Next page"><i class="fa fa-angle-right"></i></a>
    </div>
  </div>
<script src="libs/gitbook-2.6.7/js/app.min.js"></script>
<script src="libs/gitbook-2.6.7/js/clipboard.min.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-search.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-sharing.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-fontsettings.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-bookdown.js"></script>
<script src="libs/gitbook-2.6.7/js/jquery.highlight.js"></script>
<script src="libs/gitbook-2.6.7/js/plugin-clipboard.js"></script>
<script>
gitbook.require(["gitbook"], function(gitbook) {
gitbook.start({
"sharing": null,
"fontsettings": {
"theme": "white",
"family": "sans",
"size": 2
},
"edit": {
"link": "https://github.com/ajdamico/asdfree/edit/master/metadata/pirls.txt",
"text": "Edit"
},
"history": {
"link": null,
"text": null
},
"view": {
"link": null,
"text": null
},
"download": null,
"search": {
"engine": "fuse",
"options": null
},
"toc": {
"collapse": "section"
}
});
});
</script>

</body>

</html>
