gibbsR: A Gibbs sampler using R

Description Usage Arguments Value Examples

View source: R/StatComp21017R.R

Description

A Gibbs sampler using R

Usage

1
gibbsR(N, a, b, n, thin)

Arguments

N

the number of samples

a

the fixed parameter greater than 0

b

the fixed parameter greater than 0

n

the integer parameter

thin

the number of between-sample random numbers

Value

a random sample of size n

Examples

1
2
3
4
5
6
7
## Not run: 
rnR <- gibbsR(2000,1,4,50,10)
par(mfrow=c(2,1));
plot(rnR[,1],type='l')
plot(rnR[,2],type='l')

## End(Not run)

liuhyustc/StatComp21017 documentation built on Dec. 23, 2021, 11:16 p.m.