Learn R Programming

⚠️There's a newer version (2023.3.8) of this package.Take me there.

BNPdensity (version 2020.3.4)

Ferguson-Klass Type Algorithm for Posterior Normalized Random Measures

Description

Bayesian nonparametric density estimation modeling mixtures by a Ferguson-Klass type algorithm for posterior normalized random measures.

Copy Link

Version

Install

install.packages('BNPdensity')

Monthly Downloads

382

Version

2020.3.4

License

GPL (>= 2)

Maintainer

Guillaume Kon Kam King

Last Published

March 8th, 2020

Functions in BNPdensity (2020.3.4)

Enzyme1.out

Fit of MixNRMI1 function to the enzyme dataset
comment_on_NRMI_type

Comment on the NRMI process depending on the value of the parameters
comp1

Ties function: univariate
MixNRMI2

Normalized Random Measures Mixture of Type II
dt_

Non-standard student-t density
Mv

Continuous Jump heights function
dkcens2_1val

Density evaluation once
as.mcmc.multNRMI

Convert the output of multMixNRMI into a coda mcmc object
add

Add x and y
fcondYXAcens2

Conditional posterior distribution of the latents Y in the censoring case
MvInv

Invert jump heights function
cpo.NRMI1

Extract the Conditional Predictive Ordinates (CPOs) from a fitted object
asNumeric_no_warning

If the function Rmpfr::asNumeric returns a warning about inefficiency, silence it.
comp2

Ties function: bivariate
acidity

Acidity Index Dataset
give_kernel_name

Gives the kernel name from the integer code
cpo.NRMI2

Extract the Conditional Predictive Ordinates (CPOs) from a fitted object
plot.multNRMI

Plot the density estimate and the 95% credible interval
censor_code_rl

Censor code right-left
plot_prior_number_of_components

This plots the prior distribution on the number of components for the stable process. The Dirichlet process is provided for comparison.
gsHP

Updates the hyper-parameters of py0
gsYZstar

Jointly resampling Ystar and Zstar function
fcondYZXA

Conditional posterior distribution of the bivariate latents (Y,Z)
plotCDF_censored

Plot the Turnbull CDF and fitted CDF for censored data.
compute_optimal_clustering

Compute the optimal clustering from an MCMC sample
plotfit_censored

Plot the density estimate and the 95% credible interval for censored data
dk

Kernel density function
cpo.multNRMI

Extract the Conditional Predictive Ordinates (CPOs) from a list of fitted objects
qq_plot_censored

Plot the quantile-quantile graph for censored data.
dhalfcauchy

Density half Cauchy
compute_thinning_grid

Compute the grid for thinning the MCMC chain
convert_to_mcmc

Convert the output of multMixNRMI into a coda mcmc object
galaxy

Galaxy Data Set
cens_data_check

Censoring data check
fcondXA2cens2

Conditional density evaluation in the fully nonparametric model for censored data
dhalfnorm

Density half normal
MixNRMI2cens

Normalized Random Measures Mixture of Type II for censored data
qhalft

Quantile function half Student-t
cpo

Conditional predictive ordinate function
dkcens2

Density of the chosen kernel
dist_name_k_index_converter

Convert distribution names to indices
fcondYXA

Conditional posterior distribution of the latents Y
dhalft

Density half Student-t
rfyzstarcens2

Conditional posterior distribution of the distinct vectors (Ystar,Zstar) in the case of censoring
expected_number_of_components_Dirichlet

Computes the expected number of components for a Dirichlet process.
fill_sigmas

Repeat the common scale parameter of a semiparametric model to match the dimension of the location parameters.
enzyme

Enzyme Dataset
rhalfcauchy

Random number generator half Cauchy
dtnorm

Density truncated normal
grid_from_data_noncensored

Create a plotting grid from non-censored data.
gs5

Conditional posterior distribution of sigma
fcondYZXAcens2

Conditional posterior distribution of the bivariate latents (Y,Z) in the case of censoring
is_semiparametric

Tests if a fit is a semi parametric or nonparametric model.
expected_number_of_components_stable

Computes the expected number of components for a stable process.
fcondXA

Conditional density evaluation in the semiparametric model
grid_from_data

Create a plotting grid from censored or non-censored data.
rtnorm

Random number generator for a truncated normal distribution
multMixNRMI1

Multiple chains of MixNRMI1
fcondXA2

Conditional density evaluation in the fully nonparametric model
pp_plot_noncensored

Plot the percentile-percentile graph for non censored data.
print.NRMI1

S3 method for class 'MixNRMI1'
grid_from_data_censored

Create a plotting grid from censored data.
gs5cens2

Conditional posterior distribution of sigma in the case of censoring
multMixNRMI2cens

Multiple chains of MixNRMI2cens
gs3

Conditional posterior distribution of latent U
qq_plot_noncensored

Plot the quantile-quantile graph for non censored data.
gs4

Resampling Ystar function
phalft

Distribution function half Student-t
multMixNRMI1cens

Multiple chains of MixNRMI1cens
plotCDF_noncensored

Plot the empirical and fitted CDF for non censored data.
plotPDF_censored

Plot the density for censored data.
gsYZstarcens2

Jointly resampling Ystar and Zstar function in the case of censoring
pk

Kernel distribution function
multMixNRMI2

Multiple chains of MixNRMI2
plot.NRMI1

Plot the density estimate and the 95% credible interval
salinity

Salinity tolerance
gs4cens2

Resampling Ystar function in the case of censoring
p0

Centering function
plot_clustering_and_CDF

Plot the clustering and the Cumulative Distribution Function
plotPDF_noncensored

Plot the density and a histogram for non censored data.
rk

Kernel density sampling function
qt_

Quantile function non-standard Student-t
plot.NRMI2

Plot the density estimate and the 95% credible interval
process_dist_name

Process the distribution name argument into a distribution index
pp_plot_censored

Plot the percentile-percentile graph for non censored data, using the Turnbull estimator the position of the percentiles.
pt_

Distribution function non-standard student-t
plotfit_noncensored

Plot the density estimate and the 95% credible interval for noncensored data
rt_

Random number generator non-standard Student-t
is_censored

Test if the data is censored
qhalfcauchy

Quantile function half Cauchy
qhalfnorm

Quantile function half Normal
traceplot

Draw a traceplot for multiple chains
rfystarcens2

Conditional posterior distribution of the distinct Ystar in the case of censoring
rfyzstar

Conditional posterior distribution of the distinct vectors (Ystar,Zstar)
summarytext

Common text for the summary S3 methods
phalfnorm

Distribution function half Normal
print.multNRMI

S3 method for class 'multNRMI'
summary.multNRMI

S3 method for class 'multNRMI'
phalfcauchy

Distribution function half Cauchy
qgeneric

Generic function to find quantiles of a distribution
ptnorm

Distribution function truncated normal
summary.NRMI2

S3 method for class 'MixNRMI2'
rhalft

Random number generator half Student-t
qtnorm

Quantile function truncated normal
rfystar

Conditional posterior distribution of the distinct Ystar
print.NRMI2

S3 method for class 'MixNRMI2'
summary.NRMI1

S3 method for class 'MixNRMI1'
rhalfnorm

Random number generator half Normal
GOFplots

Plot Goodness of fits graphical checks for censored data
GOFplots_noncensored

Plot Goodness of fits graphical checks for non censored data
MixNRMI1

Normalized Random Measures Mixture of Type I
GOFplots_censored

Plot Goodness of fits graphical checks for censored data
Galaxy2.out

Fit of MixNRMI2 function to the galaxy dataset
Galaxy1.out

Fit of MixNRMI1 function to the galaxy dataset
BNPdensity-package

Bayesian nonparametric density estimation
Enzyme2.out

Fit of MixNRMI2 function to the enzyme dataset
MixNRMI1cens

Normalized Random Measures Mixture of Type I for censored data