SVILD: Summaries of Variability of Irregularly Spaced Longitudinal...

Description Usage Arguments Value Note Author(s) Examples

View source: R/SVILD.R

Description

Read raw data into R and create a list to store all variables of patients

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
	SVILD(id, ...)

	## Default S3 method:
SVILD(id, time,y, timeFormat = "%d%b%y:%H:%M:%S", ...)
	## S3 method for class 'SVILD'
print(x, ...)
	## S3 method for class 'SVILD'
summary(object, ...)
	## S3 method for class 'SVILD'
plot(object, n=12, ...)

Arguments

id

a numeric vector of patients.

time

a date time vector.

y

a numeric vector of response glucose.

timeFormat

format of date time used.

object

an object of class SVILD.

n

number of patients plotted.

x

an object

...

not used.

Value

An object of class is a list including basic elements:

ID

unique ID

y

response y

lag.y

lagged y values

diff.y

difference between two sequence time

fmttime

formatted date time

time

rescaled number of time

lag.time

lagged time

diff.time

difference between two sequence time

Note

Additional indices will add soon

Author(s)

Dongsheng Yang, Anne S. Tang

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
id = c(17, 17, 17, 17, 17, 17, 17, 17, 17, 17, 21, 21, 21, 21, 21, 21, 21, 
30, 30, 30, 30, 30, 30, 30)

y = c(110, 137, 142, 129, 102, 113, 195, 168, 192, 156, 178, 186, 116, 105, 
111, 86, 113, 115, 106, 113, 115, 106, 97, 103)
	  
time = c("05JUL07:15:10:00", "05JUL07:16:15:00", "05JUL07:17:15:00", 
"05JUL07:18:15:00", "05JUL07:19:15:00", "05JUL07:20:00:00", "05JUL07:21:10:00", 
"05JUL07:21:40:00", "05JUL07:22:10:00", "05JUL07:22:40:00", "10MAY07:08:15:00", 
"10MAY07:09:15:00", "10MAY07:10:15:00", "10MAY07:10:30:00", "10MAY07:11:00:00", 
"10MAY07:11:30:00", "10MAY07:12:20:00", "12JUL07:08:15:00", "12JUL07:08:20:00", 
"12JUL07:09:15:00", "12JUL07:09:20:00", "12JUL07:10:15:00", "12JUL07:10:20:00", 
"12JUL07:11:10:00")
	
mylist = SVILD(id = id, time = time, y = y, timeFormat = "%d%b%y:%H:%M:%S")
print(mylist)
summary(mylist)
plot(mylist, n = 5)

SVILD documentation built on May 31, 2017, 4:21 a.m.