Last data update: 2014.03.03

R: Simulated Decreasing Data
simDEC_dataR Documentation

Simulated Decreasing Data

Description

This data was simulated to be monotonically decreasing. There are 500 individuals, with a random number of data points. Each individual has a two-level random effect (intercept and slope), a common intercept, and a random error term. The ages range from 0 to 10 years, which is given in months.

Usage

data("simDEC_data")

Format

A data frame with 5505 observations on the following 3 variables.

id

a numeric vector of the identification number of each individual

age

a numeric vector of the age in months

y

a numeric vector of measurements

References

http://blog.stata.com/2014/07/18/how-to-simulate-multilevellongitudinal-data/

Examples

data(simDEC_data)
library(sitar)

mplot(x=age, y=y, id=id, data=simDEC_data, col=id, main="Individual Measurement Curves")	

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(MonoInc)
Loading required package: compare

Attaching package: 'compare'

The following object is masked from 'package:base':

    isTRUE

Loading required package: doParallel
Loading required package: foreach
Loading required package: iterators
Loading required package: parallel
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/MonoInc/simDEC_data.Rd_%03d_medium.png", width=480, height=480)
> ### Name: simDEC_data
> ### Title: Simulated Decreasing Data
> ### Aliases: simDEC_data
> ### Keywords: datasets
> 
> ### ** Examples
> 
> data(simDEC_data)
> library(sitar)
Loading required package: nlme
Loading required package: splines
> 
> mplot(x=age, y=y, id=id, data=simDEC_data, col=id, main="Individual Measurement Curves")	
> 
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>