make_tfd_dist | R Documentation |
Families for deepregression
make_tfd_dist(family, add_const = 1e-08, output_dim = 1L, trafo_list = NULL)
family |
character vector |
add_const |
small positive constant to stabilize calculations |
output_dim |
number of output dimensions of the response (larger 1 for multivariate case) |
trafo_list |
list of transformations for each distribution parameter. Per default the transformation listed in details is applied. |
To specify a custom distribution, define the a function as follows
function(x) do.call(your_tfd_dist, lapply(1:ncol(x)[[1]],
function(i)
your_trafo_list_on_inputs[[i]](
x[,i,drop=FALSE])))
and pass it to deepregression
via the dist_fun
argument.
Currently the following distributions are supported
with parameters (and corresponding inverse link function in brackets):
"normal": normal distribution with location (identity), scale (exp)
"bernoulli": bernoulli distribution with logits (identity)
"bernoulli_prob": bernoulli distribution with probabilities (sigmoid)
"beta": beta with concentration 1 = alpha (exp) and concentration 0 = beta (exp)
"betar": beta with mean (sigmoid) and scale (sigmoid)
"cauchy": location (identity), scale (exp)
"chi2": cauchy with df (exp)
"chi": cauchy with df (exp)
"exponential": exponential with lambda (exp)
"gamma": gamma with concentration (exp) and rate (exp)
"gammar": gamma with location (exp) and scale (exp), following
gamlss.dist::GA
, which implies that the expectation is the location,
and the variance of the distribution is the location^2 scale^2
"gumbel": gumbel with location (identity), scale (exp)
"half_cauchy": half cauchy with location (identity), scale (exp)
"half_normal": half normal with scale (exp)
"horseshoe": horseshoe with scale (exp)
"inverse_gamma": inverse gamma with concentation (exp) and rate (exp)
"inverse_gamma_ls": inverse gamma with location (exp) and variance (1/exp)
"inverse_gaussian": inverse Gaussian with location (exp) and concentation (exp)
"laplace": Laplace with location (identity) and scale (exp)
"log_normal": Log-normal with location (identity) and scale (exp) of underlying normal distribution
"logistic": logistic with location (identity) and scale (exp)
"negbinom": neg. binomial with count (exp) and prob (sigmoid)
"negbinom_ls": neg. binomail with mean (exp) and clutter factor (exp)
"pareto": Pareto with concentration (exp) and scale (1/exp)
"pareto_ls": Pareto location scale version with mean (exp) and scale (exp), which corresponds to a Pareto distribution with parameters scale = mean and concentration = 1/sigma, where sigma is the scale in the pareto_ls version
"poisson": poisson with rate (exp)
"poisson_lograte": poisson with lograte (identity))
"student_t": Student's t with df (exp)
"student_t_ls": Student's t with df (exp), location (identity) and scale (exp)
"uniform": uniform with upper and lower (both identity)
"zinb": Zero-inflated negative binomial with mean (exp), variance (exp) and prob (sigmoid)
"zip": Zero-inflated poisson distribution with mean (exp) and prob (sigmoid)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.