HPQLIM Procedure

Prior Distributions

The PRIOR statement specifies the prior distribution of the model parameters. You must specify one parameter or a list of parameters, a tilde tilde, and then a distribution with its parameters. You can specify multiple PRIOR statements to define independent priors. Parameters that are associated with a regressor variable are referred to by the name of the corresponding regressor variable.

You can specify the special keyword _REGRESSORS to consider all the regressors of a model. If multiple PRIOR statements affect the same parameter, the last PRIOR statement prevails. For example, in a regression with two regressors (X1, X2), the following statements imply that the prior on X1 is NORMAL(MEAN=0, VAR=1) and the prior on X2 is GAMMA(SHAPE=3, SCALE=4):

...
prior _Regressors ~ uniform(min=0, max=1);
prior X1 X2 ~ gamma(shape=3, scale=4);
prior X1 ~ normal(mean=0, var=1);
...

If a parameter is not associated with a PRIOR statement or if some of the prior hyperparameters are missing, then the default choices in Table 3 are considered.

Table 3: Default Values for Prior Distributions

PRIOR Distribution sans-serif upper H sans-serif y sans-serif p sans-serif e sans-serif r sans-serif p sans-serif a sans-serif r sans-serif a sans-serif m sans-serif e sans-serif t sans-serif e sans-serif r Subscript 1 sans-serif upper H sans-serif y sans-serif p sans-serif e sans-serif r sans-serif p sans-serif a sans-serif r sans-serif a sans-serif m sans-serif e sans-serif t sans-serif e sans-serif r Subscript 2 sans-serif upper M sans-serif i sans-serif n sans-serif upper M sans-serif a sans-serif x Parameters Default Choice
NORMAL MEAN=0 VAR=1E6 negative normal infinity normal infinity sans-serif upper R sans-serif e sans-serif g sans-serif r sans-serif e sans-serif s sans-serif s sans-serif i sans-serif o sans-serif n minus sans-serif upper L sans-serif o sans-serif c sans-serif a sans-serif t sans-serif i sans-serif o sans-serif n minus sans-serif upper T sans-serif h sans-serif r sans-serif e sans-serif s sans-serif h sans-serif o sans-serif l sans-serif d
IGAMMA SHAPE=2.000001 SCALE=1 greater-than 0 normal infinity sans-serif upper S sans-serif c sans-serif a sans-serif l sans-serif e
GAMMA SHAPE=1 SCALE=1 sans-serif 0 normal infinity
UNIFORM negative normal infinity normal infinity
BETA SHAPE1=1 SHAPE2=1 negative normal infinity normal infinity
T LOCATION=0 DF=3 negative normal infinity normal infinity


For density specification, see the section Standard Distributions.

Standard Distributions

Table 4 through Table 9 show all the distribution density functions that PROC HPQLIM recognizes. You specify these distribution densities in the PRIOR statement.

Table 4: Beta Distribution

PRIOR statement BETA(SHAPE1=a, SHAPE2=b, MIN=m, MAX=M)
Note: Commonly m equals 0 and upper M equals 1.
Density StartFraction left-parenthesis theta minus m right-parenthesis Superscript a minus 1 Baseline left-parenthesis upper M minus theta right-parenthesis Superscript b minus 1 Baseline Over upper B left-parenthesis a comma b right-parenthesis left-parenthesis upper M minus m right-parenthesis Superscript a plus b minus 1 Baseline EndFraction
Parameter restriction a greater-than 0, b greater-than 0, negative normal infinity less-than m less-than upper M less-than normal infinity
Range StartLayout Enlarged left-brace 1st Row 1st Column left-bracket m comma upper M right-bracket 2nd Column when a equals 1 comma b equals 1 2nd Row 1st Column left-bracket m comma upper M right-parenthesis 2nd Column when a equals 1 comma b not-equals 1 3rd Row 1st Column left-parenthesis m comma upper M right-bracket 2nd Column when a not-equals 1 comma b equals 1 4th Row 1st Column left-parenthesis m comma upper M right-parenthesis 2nd Column otherwise EndLayout
Mean StartFraction a Over a plus b EndFraction times left-parenthesis upper M minus m right-parenthesis plus m
Variance StartFraction a b Over left-parenthesis a plus b right-parenthesis squared left-parenthesis a plus b plus 1 right-parenthesis EndFraction times left-parenthesis upper M minus m right-parenthesis squared
Mode StartLayout Enlarged left-brace 1st Row 1st Column StartFraction a minus 1 Over a plus b minus 2 EndFraction times upper M plus StartFraction b minus 1 Over a plus b minus 2 EndFraction times m 2nd Column a greater-than 1 comma b greater-than 1 2nd Row 1st Column m and upper M 2nd Column a less-than 1 comma b less-than 1 3rd Row 1st Column m 2nd Column StartLayout Enlarged left-brace 1st Row  a less-than 1 comma b greater-than-or-equal-to 1 2nd Row  a equals 1 comma b greater-than 1 EndLayout 4th Row 1st Column upper M 2nd Column StartLayout Enlarged left-brace 1st Row  a greater-than-or-equal-to 1 comma b less-than 1 2nd Row  a greater-than 1 comma b equals 1 EndLayout 5th Row 1st Column not unique 2nd Column a equals b equals 1 EndLayout
Defaults SHAPE1=SHAPE2=1, sans-serif upper M sans-serif upper I sans-serif upper N right-arrow negative normal infinity, sans-serif upper M sans-serif upper A sans-serif upper X right-arrow normal infinity


Table 5: Gamma Distribution

PRIOR statement GAMMA(SHAPE=a, SCALE=b)
Density StartFraction 1 Over b Superscript a Baseline normal upper Gamma left-parenthesis a right-parenthesis EndFraction theta Superscript a minus 1 Baseline e Superscript negative theta slash b
Parameter restriction a greater-than 0 comma b greater-than 0
Range left-bracket 0 comma normal infinity right-parenthesis
Mean a b
Variance a b squared
Mode left-parenthesis a minus 1 right-parenthesis b
Defaults SHAPE=SCALE=1


Table 6: Inverse Gamma Distribution

PRIOR statement IGAMMA(SHAPE=a, SCALE=b)
Density StartFraction b Superscript a Baseline Over normal upper Gamma left-parenthesis a right-parenthesis EndFraction theta Superscript minus left-parenthesis a plus 1 right-parenthesis Baseline e Superscript negative b slash theta
Parameter restriction a greater-than 0 comma b greater-than 0
Range 0 less-than theta less-than normal infinity
Mean StartFraction b Over a minus 1 EndFraction comma a greater-than 1
Variance StartFraction b squared Over left-parenthesis a minus 1 right-parenthesis squared left-parenthesis a minus 2 right-parenthesis EndFraction comma a greater-than 2
Mode StartFraction b Over a plus 1 EndFraction
Defaults SHAPE=2.000001, SCALE=1


Table 7: Normal Distribution

PRIOR statement NORMAL(MEAN=mu, VAR=sigma squared)
Density StartFraction 1 Over sigma StartRoot 2 pi EndRoot EndFraction exp left-parenthesis minus StartFraction left-parenthesis theta minus mu right-parenthesis squared Over 2 sigma squared EndFraction right-parenthesis
Parameter restriction sigma squared greater-than 0
Range negative normal infinity less-than theta less-than normal infinity
Mean mu
Variance sigma squared
Mode mu
Defaults MEAN=0, VAR=1000000


Table 8: t Distribution

PRIOR statement T(LOCATION=mu, DF=nu)
Density StartStartFraction normal upper Gamma left-parenthesis StartFraction nu plus 1 Over 2 EndFraction right-parenthesis OverOver normal upper Gamma left-parenthesis StartFraction nu Over 2 EndFraction right-parenthesis StartRoot pi nu EndRoot EndEndFraction left-bracket 1 plus StartFraction left-parenthesis theta minus mu right-parenthesis squared Over nu EndFraction right-bracket Superscript minus StartFraction nu plus 1 Over 2 EndFraction
Parameter restriction nu greater-than 0
Range negative normal infinity less-than theta less-than normal infinity
Mean mu comma for nu greater-than 1
Variance StartFraction nu Over nu minus 2 EndFraction comma for nu greater-than 2
Mode mu
Defaults LOCATION=0, DF=3


Table 9: Uniform Distribution

PRIOR statement UNIFORM(MIN=m, MAX=M)
Density StartFraction 1 Over upper M minus m EndFraction
Parameter restriction negative normal infinity less-than m less-than upper M less-than normal infinity
Range theta element-of left-bracket m comma upper M right-bracket
Mean StartFraction m plus upper M Over 2 EndFraction
Variance StartFraction left-parenthesis upper M minus m right-parenthesis squared Over 12 EndFraction
Mode Not unique
Defaults MINright-arrow negative normal infinity, MAXright-arrow normal infinity


Last updated: June 19, 2025