vis.hist: Histogram of posterior distribution

View source: R/vis.hist.R

vis.histR Documentation

Histogram of posterior distribution

Description

Create histogram of posterior distribution and compute posterior distribution statistics (p-values and confidence interval).

Usage

vis.hist(
  x,
  quantile = c(0.05, 0.95),
  backgroud.color = "gray63",
  observe.value.color = "white",
  ci.lower.color = "white",
  ci.upper.color = "white",
  xlab = NULL,
  main = NULL,
  legend = TRUE,
  legend.position = "topright",
  record = TRUE
)

Arguments

x

A numeric vector with the first value corresponding to the observed value.

quantile

a numeric vector of length 2 to indicate the lower and upper confidence interval.

backgroud.color

A specification for the default histogram background color.

observe.value.color

A specification for the default abline line color of the observed value.

ci.lower.color

A specification for the default abline line color of the lower confidence interval.

ci.upper.color

A specification for the default abline line color of the lower confidence interval.

xlab

A string for x axis label.

main

A string for histogram main title.

legend

A bolean to print or not the legend

legend.position

The x co-ordinates to be used to position the legend. They can be specified by keyword or in any way which is accepted by xy.coords:

record

A bolean indicating to return or not the histogram in a R object.

Examples

t=met.strength(sim.m,sim.df,1) # Computing network metric
t=perm.net.nl(t,labels='age',rf=NULL,nperm=1000,progress=FALSE) # Node label permutations
r.c=stat.cor(t,'age','strength',progress=FALSE) # Permuted correlation test
vis.hist(r.c[,1])# Histogram of posterior distribution

SebastianSosa/ant documentation built on Sept. 23, 2023, 7:06 a.m.