nlschools.html

来自「本程序是基于linux系统下c++代码」· HTML 代码 · 共 89 行

HTML
89
字号
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><title>R: Eighth-Grade Pupils in the Netherlands</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" type="text/css" href="../../R.css">
</head><body>

<table width="100%" summary="page for nlschools {MASS}"><tr><td>nlschools {MASS}</td><td align="right">R Documentation</td></tr></table>
<h2>Eighth-Grade Pupils in the Netherlands</h2>


<h3>Description</h3>

<p>
Snijders and Bosker (1999) use as a running example a study of 2287
eighth-grade pupils (aged about 11) in 132 classes in 131 schools in
the Netherlands.  Only the variables used in our examples are supplied.
</p>


<h3>Usage</h3>

<pre>
nlschools
</pre>


<h3>Format</h3>

<p>
This data frame contains 2287 rows and the following columns:
<dl>
<dt><code>lang</code></dt><dd>language test score
</dd>
<dt><code>IQ</code></dt><dd>Verbal IQ
</dd>
<dt><code>class</code></dt><dd>class ID
</dd>
<dt><code>GS</code></dt><dd>Class size: number of eighth-grade pupils recorded in the class (there
may be others: see <code>COMB</code>, and some may have been omitted with missing
values).
</dd>
<dt><code>SES</code></dt><dd>Social-economic status of pupil's family.
</dd>
<dt><code>COMB</code></dt><dd>were the pupils taught in a multi-grade class (<code>0/1</code>)?  Classes which
contained pupils from grades 7 and 8 are coded <code>1</code>, but only
eighth-graders were tested.
</dd></dl>

<h3>Source</h3>

<p>
Snijders, T. A. B. and Bosker, R. J. (1999)
<EM>Multilevel Analysis. An Introduction to Basic and Advanced Multilevel Modelling.</EM>
London: Sage.
</p>


<h3>References</h3>

<p>
Venables, W. N. and Ripley, B. D. (2002)
<EM>Modern Applied Statistics with S.</EM> Fourth edition.  Springer.
</p>


<h3>Examples</h3>

<pre>
library(nlme)
nl1 &lt;- nlschools
attach(nl1)
classMeans &lt;- tapply(IQ, class, mean)
nl1$IQave &lt;- classMeans[as.character(class)]
nl1$IQ &lt;- nl1$IQ - nl1$IQave
detach()
cen &lt;- c("IQ", "IQave", "SES")
nl1[cen] &lt;- scale(nl1[cen], center = TRUE, scale = FALSE)

nl.lme &lt;- lme(lang ~ IQ*COMB + IQave + SES,
              random = ~ IQ | class, data = nl1)
summary(nl.lme)
</pre>



<hr><div align="center">[Package <em>MASS</em> version 7.2-44 <a href="00Index.html">Index]</a></div>

</body></html>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?