# NOT RUN {
# Loading datasets
data(simple.band1)
data(simple.band2)
# Doubly-lensed quasar data set observed in two bands
# Each data set contains doubly-lensed light curves observed in one band.
head(simple.band1)
head(simple.band2)
# The length of each data set (i.e., number of observation times)
# do not need to be the same.
dim(simple.band1)
dim(simple.band2)
###############################################
# Time delay estimation via Bayesian approach #
###############################################
# Cubic microlensing model (m = 3)
# }
# NOT RUN {
output <- bayesian.multiband(data.band1 = simple.band1,
data.band2 = simple.band2, n.bands = 2,
theta.ini = c(0.01, 0.01, 100, 100, 0.5),
delta.ini = 100, delta.uniform.range = c(-500, 500),
tau.proposal.scale = 1, tau.prior.shape = 1, tau.prior.scale = 1,
sigma2.proposal.scale = 0.5, sigma2.prior.shape = 1, sigma2.prior.scale = 1e-7,
rho.proposal.scale = 0.1, beta.prior.diag = 10 * c(0.1, 0.01, 1e-3, 1e-5)^2,
micro = 3, timesc = 100, adaptive.frequency = 100,
adaptive.delta.factor = 0.1, adaptive.tau.factor = 0.1,
adaptive.sigma2.factor = 0.1, adaptive.rho.factor = 0.1,
sample.size = 100, warmingup.size = 100)
names(output)
# }
# NOT RUN {
# hist(output$delta, 20)
# plot(output$delta, type = "l")
# acf(output$delta)
# output$delta.accept.rate
# }
Run the code above in your browser using DataLab