Class
NumCosmoMathPrior
Description [src]
class NumCosmoMath.Prior : NumCosmoMath.MSetFunc
{
/* No available fields */
}
Base class for prior distributions.
This object defines a base class for priors used by NcmLikelihood. These objects
describe prior distributions applicable to parameters or any derived quantity. A
prior returns one of two quantities, see ncm_prior_is_m2lnL():
- $-2\ln P$, added to $-2\ln L$ as it is;
- $f$ such that $-2\ln P = f^2$, added to $-2\ln L$ as $f^2$.
The second form is also a least-squares residual, so those priors can be used by the least-squares fits as well as by any other analysis.
Instance methods
Methods inherited from NcmMSetFunc (23)
ncm_mset_func_eval
Evaluates func at x and stores its values in res. If x is NULL, func is
evaluated at the point set by ncm_mset_func_set_eval_x(); a function without
variables takes no arguments.
ncm_mset_func_eval0
Evaluates the scalar function func and returns its value. The arguments are the
point set by ncm_mset_func_set_eval_x(), or none if func has no variables.
ncm_mset_func_eval1
Evaluates the scalar function func at x and returns its value. func takes at
most one variable; a function without variables ignores x. The point set by
ncm_mset_func_set_eval_x(), if any, is not used.
ncm_mset_func_eval_array
Evaluates func at x and returns its values. If x is NULL, func is evaluated
at the point set by ncm_mset_func_set_eval_x(); a function without variables
takes no arguments. This is ncm_mset_func_eval() for language bindings, where
the values of ncm_mset_func_eval() do not reach the caller.
ncm_mset_func_eval_nvar
Evaluates the scalar function func at x and returns its value. If x is NULL,
func is evaluated at the point set by ncm_mset_func_set_eval_x(); a function
without variables takes no arguments.
ncm_mset_func_eval_vector
Evaluates the scalar function func at each component of x_v and stores the
values in the matching components of res_v. func takes at most one variable; a
function without variables ignores x_v. The point set by
ncm_mset_func_set_eval_x(), if any, is not used.
ncm_mset_func_free
Decreases the reference count of func by one. If the reference count
reaches zero, func is freed.
ncm_mset_func_get_dim
Gets the dimension of func.
ncm_mset_func_get_nvar
Gets the number of variables of func.
ncm_mset_func_has_nvar
Checks if func expects nvar extra variables.
ncm_mset_func_is_const
Checks if func is a constant function.
ncm_mset_func_is_scalar
Checks if func is a scalar function.
ncm_mset_func_is_vector
Checks if func is a vectorial function with dimension dim.
ncm_mset_func_numdiff_fparams
Computes the gradient of the scalar function func at x with respect to the free
parameters of mset and stores it in out. If out is NULL, a new NcmVector
is allocated; otherwise out must have one component per free parameter and is overwritten.
ncm_mset_func_peek_desc
ncm_mset_func_peek_name
ncm_mset_func_peek_ns
ncm_mset_func_peek_symbol
ncm_mset_func_peek_uname
Peeks unique name.
ncm_mset_func_peek_usymbol
Peeks unique symbol.
ncm_mset_func_ref
Increases the reference count of func by one.
ncm_mset_func_set_eval_x
Sets the evaluation point of func to a copy of x. Evaluations without
arguments use it, func becomes constant (see ncm_mset_func_is_const()) and its
unique name and symbol encode it.
ncm_mset_func_set_meta
Sets the function’s metadata. This function is called by subclasses’ to set the function’s metadata. It should not be called by users.
Properties
Properties inherited from NcmMSetFunc (3)
NumCosmoMath.MSetFunc:dimension
The number of values the function returns.
NumCosmoMath.MSetFunc:eval-x
The evaluation point set by ncm_mset_func_set_eval_x(), or NULL. Setting it
copies the vector, which must have NcmMSetFunc:nvariables components.
NumCosmoMath.MSetFunc:nvariables
The number of variables the function takes besides the models.
Signals
Signals inherited from GObject (1)
GObject::notify
The notify signal is emitted on an object when one of its properties has its value set through g_object_set_property(), g_object_set(), et al.