Heatmap: Heatmap

Description Usage Arguments Value Examples

View source: R/heatmap.R

Description

Generate a heatmap to show different activity intensities (in MET) at different time of different days.

Usage

1

Arguments

data

A csv file for one participant with multiple days' activity records from SenseWear. Data format refers to provided sampledata.

a

The desired cutpoints of METs. Lower and upper limits must be specified. E.g. a=c(0,3,5,7). 0 and 7 are the lower and upper limit, respectively.

category

Default is FALSE which means treating METs as continuous. category=TRUE and a valid cutpoints a will categorize METs by a. If category=TRUE while no a is specified, METs will be treated as continuous.

Value

graph A heatmap generated by ggplot with x axis Time and y axis Date

Examples

1
2
3
4
#Continuous METs
Heatmap(sampledata);
#Categorical METs with cutpoint 0,3,5,7
 Heatmap(sampledata,c(0,3,5,7),category=TRUE)

Example output

Loading required package: ggplot2

PASenseWear documentation built on May 2, 2019, 2:22 p.m.