ds.box: Boxplot Parameters of a numeric vector

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/ds.box.R

Description

This function calculates the statistical measures needed to visualize the boxplot of a numeric vector.

Usage

1
ds.box(x, c=1.5, c.width = 0.15 , out = TRUE, tojson=FALSE)

Arguments

x

The input numeric vector

c

Determines the length of the "whiskers" plot. If it is equal to zero or out=F, no outliers will be returned.

c.width

The width level is determined 0.15 times the square root of the size of the input vector

out

If TRUE the outliers will be computed at the selected "c" level (default is 1.5 times the Interquartile Range).

tojson

If TRUE the results are returned in json format

Details

This function returns a list with the parameters needed to visualize a boxplot.

Value

Returns a list or a json file with the following components:

Author(s)

Kleanthis Koupidis, Charalampos Bratsas

See Also

ds.analysis, open_spending.ds

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
# with vector as an input and the default parameters
vec <- as.vector(iris$Sepal.Width)
ds.box(vec)

# with vector as an input and the different parameters
vec <- as.vector(iris$Sepal.Width)
ds.box(vec, c = 3, c.width = 0.20 , out = FALSE, tojson = FALSE)

# OpenBudgets.eu Dataset Example:
amounts <- as.vector(Wuppertal_df$Amount)
ds.box(amounts, c = 1.5, c.width = 0.20, out = TRUE)

DescriptiveStats.OBeu documentation built on May 8, 2018, 5:04 p.m.