kaneplusplus / basket Goto Github PK
View Code? Open in Web Editor NEWMultisource Exchangeability Models
Multisource Exchangeability Models
Do we want to remove it from the package for now?
Incorporate cluster analysis into full_bayes_mcmc()
Organize full_bayes_mcmc() output into 3 lists
summary function
post prob
hpd
median
mean
ESS
Update function to re-compute posterior prob with new p0
Plot function
Make full_bayes_exact() consistent with full_bayes_mcmc()
unique to exact = PEP and posterior probability
Hi there,
I currently use the mem_exact function a lot for simulations with a relatively small number of baskets (3-5). I noticed that the function only calculates the posterior probabilities exactly, but the posterior mean, median and HPD-intervals are still estimated from MCMC samples. This slows down computation a lot, since 100.000 samples are drawn and there is no way to change this. Drawing the posterior samples takes much longer than calculating the exact posterior probabilities for a small number of baskets.
Is there a specific reason that the rest of the output isn't also calculated exactly? Since the posterior weights are already calculated in the function, it seems that it would be much faster to also calculate the posterior mean and median exactly. It would be awesome if this could be changed!
The following code shows that there is one cluster found but there are 3 Nulls (one for each basket). This is confusing.
library(basket)
data(vemu_wide)
baskets <- 1:3
vemu_wide1 <- vemu_wide[baskets,]
mcmc_res1 <- mem_mcmc(
responses = vemu_wide1$responders,
size = vemu_wide1$evaluable,
name = vemu_wide1$baskets,
p0 = 0.15)
mcmc_res1$cluster$post.prob
mcmc_res1$cluster$p0
Two things still need to be done for the SEM implementation:
data-raw
directory.Code is available on the Presagia One Drive.
The original code should be added to the basket/inst/
directory.
From the JSS editor:
The diverging color scale in Figure 4 is rather unbalanced and not ideal
for viewers with color vision deficiencies. For example,
grDevices::hcl.colors() offers "Green-Brown" or "Blue-Red 3". But other
packages like RColorBrewer, rcartocolors, colorspace, etc. also offer
alternatives.
logMarg.Dens
logMarg.DensSA
logMarg.DensPE
Code coverage needs to get above 90%.
cluster_PEP
should take an mem object, not the individual parameters containted by an mem object.
library(basket)
data(vemu_wide)
baskets <- 1:2
vemu_wide1 <- vemu_wide[baskets,]
mcmc_res1 <- mem_mcmc(
responses = vemu_wide1$responders,
size = vemu_wide1$evaluable,
name = vemu_wide1$baskets,
p0 = 0.15)
# Results in Error in rep(1, dim(mod.mat[[1]])[1]) : invalid 'times' argument
This should be done in mem_full_bayes
and mem_empirical_bayes
.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.