# Distribution tests - vector parameters

I’m working on writing distribution tests for the ordered logistic distribution, but all of the other tests have scalar input parameters, for example, `normal_test.hpp`:

``````    vector<double> param(3);

param = 0;  // y
param = 0;  // mu
param = 1;  // sigma
parameters.push_back(param);
log_prob.push_back(-0.918938533204672669541);  // expected log_prob
``````

Whereas I need `param` to be a vector of doubles.

Is there a different way that I should be parameterising this?

What do the existing tests look like? And what about tests for things like multivariate normal, or the Dirichlet, both of which involve vector-only parameters.

All of the existing tests are for the univariate distributions. Looking at `test/prob`:

• bernoulli
• beta
• beta_binomial
• beta_proportion
• cauchy
• chi_square
• double_exponential
• exp_mod_normal
• exponential
• frechet
• gamma
• gumbel
• hypergeometric
• inv_chi_square
• inv_gamma
• logistic
• lognormal
• neg_binomial
• neg_binomial_2
• normal
• normal_sufficient
• pareto
• pareto_type_2
• poisson
• rayleigh
• scaled_inv_chi_square
• skew_normal
• std_normal
• student_t
• uniform binomial
• von_mises
• weibull
• wiener

So there aren’t any distributions with vector parameters being tested

There were some that Rob Trangucci wrote; I think they were vectorized.

We hadn’t been able to write a generic framework for these pre C++11. I think we can actually start making a lot of progress now, but that may not help you test things in the short term. I’d start by writing tests manually. And then trying to derive requirements from that.

You need to look in `test/unit/math/prim/mat/prob/`

They’re all being done by hand, which is a mess. I’d suggest at the very least using my new testing framework.