bayes.1: Bayesian Regression Function

Description Usage Arguments Value Examples

View source: R/bayes.1.R

Description

Bayesian Regression Function

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
bayes.1(
  y,
  a,
  b,
  df,
  name.dep,
  b.0 = 0,
  d.0 = 0.001,
  c.0 = 0.001,
  burn.in = 1000
)

Arguments

y

the column number in the data frame for the dependent variable

a

the start column number in the data frame for the independent variables

b

the end column number in the data frame for the independent variables. The independent variables MUST be consecutive

df

data frame for the regression

name.dep

name of the dependent variable. Important for doing regression.

b.0

prior mean of beta. Set to mcmcRegress default, but can be updated by the user

d.0

prior scale parameter. Set to mcmcRegress default, but can be updated by the user

c.0

prior shape parameter. Set to mcmcRegress default, but can be updated by the user

burn.in

value for the burn.in. Set to mcmcRegress defualt, but can be updated by the user

Value

Summary statistics for classical regression

Confidence intervals for classical regression

Summary statistics for Bayesian regression

Posterior plots of marginal distributions

Posterior MCMC Trace and History Plots

Posterior Diagnostics

Examples

1
2
data <- diamonds
bayes.1(y = 1, a = 2, b = 3, df = data, name.dep = "price")

leahpom/F2020Projt3LP documentation built on Jan. 1, 2021, 8:17 a.m.