plot_arse: Plots the area of resilience to stress event.

Description Usage Arguments Value Examples

Description

This function takes a series of 'x,y' coordinates and a specified 'y' baseline value and plots them on an x- and y-axis.

Usage

1
plot_arse(xcoord, ycoord, ybase = NA, ll, ul, xlab = NA, ylab = NA)

Arguments

xcoord

A specified selection of the x-coordinate values within a vector. The first x-coordinate value should correspond to the baseline input of 'y'.

ycoord

A specified selection of the y-coordinate values within a vector. The first y-coordinate value should correspond to the baseline value of 'y'. The second y-coordinate value should be the first measure of 'y' after the intrusion of a stress event. The last value of 'y' should correspond to the last measurement of 'y' over the measured timeframe.

ybase

A specified selection of the baseline of the 'y' measured variable. Users are advised to place baseline as the first instance of the y-coordinate values. Function defaults to use the first y-coordinate value in the series.

ll

Sets the lower limit of the y-axis scale. Recommended to be the lowest possible value of your 'y' measure.

ul

Sets the upper limit of the y-axis scale. Recommended to be the highest possible value of your 'y' measure.

xlab

Labels the x-axis. Defaults to "Time (X)".

ylab

Labels the y-axis. Defaults to "Outcome (Y)".

Value

Returns a graph with 'x,y' coordinates and baseline.

Examples

1
2
3
4
5
xc <- t(c(1,2,3,4,5,6,7,8,9,10))
yc <- t(c(75,53,37,25,27,35,50,75,75,75))
dataset1 <- data.frame(xc, yc)
plot_arse(xcoord = as.numeric(dataset1[,1:10]),
ycoord = as.numeric(dataset1[,11:20]), ll = 0, ul = 100)

arse documentation built on May 10, 2019, 5:03 p.m.