HRQoLplot: Spider plot of the dimensions of the Short Form-36 Health...

Description Usage Arguments Details Author(s) See Also Examples

Description

This function creates a spider plot with all the 8 dimensions of the SF-36 questionnaire indicating the HRQoL score of each observation.

Usage

1

Arguments

data

a data frame with each column relative to observations of each dimension. The columns of the data frame must be introduced in the following order:

  1. column -> Role Physical

  2. column -> Role Emotional

  3. column -> Physical Functioning

  4. column -> Vitality

  5. column -> Social Functioning

  6. column -> Body Pain

  7. column -> General Health

  8. column -> Mental Health

legend

logical parameter, if TRUE the legend with the name of the rows of the data will appear. FALSE has been taken by default.

Details

The HRQoLplot has a data frame object as input, and an optional legend logical input. The data frame must have observations of the HRQoL taken by the SF-36 and the columns of the data frame will refer to each domain of the SF-36, hence the data frame must have eight columns. Each axis of the plot refers to an especific HRQoL domain, so the order of the data frame columns must be as it is showed in the arguments section. The HRQoL score of each observation (row) of the data frame is drawn with a line of a different color in the plot.

Author(s)

Josu Najera-Zuloaga

Dae-Jin Lee

This function depends on the function radarchart of the package fmsb created by Minato Nakazawa.

See Also

As it is said in the author section, the function depends on the function radarchart of the package fmsb

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
set.seed(5)
# We insert the columns in the order that has been determined:
n <- c(4,3,20,20,8,9,20,13)
k=3
p=runif(8,0,1)
phi <- runif(8,1,3)
dat <- data.frame(
  RP=rBB(k,n[1],p[1],phi[1]),
  RE=rBB(k,n[2],p[2],phi[2]),
  PF=rBB(k,n[3],p[3],phi[3]),
  VT=rBB(k,n[4],p[4],phi[4]),
  SF=rBB(k,n[5],p[5],phi[5]),
  BP=rBB(k,n[6],p[6],phi[6]),
  GH=rBB(k,n[7],p[7],phi[7]),
  MH=rBB(k,n[8],p[8],phi[8]))

rownames(dat) <- c("ID1", "ID2", "ID3")
HRQoLplot(dat,TRUE)

idaejin/HRQoL documentation built on May 18, 2019, 2:32 a.m.