All functions


Random generation of datasets using the dirichlet broken stick method


Data from Satterthwaite, W.H., Ciancio, J., Crandall, E., Palmer-Zwahlen, M.L., Grover, A.M., O’Farrell, M.R., Anson, E.C., Mohr, M.S. & Garza, J.C. (2015). Stock composition and ocean spatial distribution from California recreational chinook salmon fisheries using genetic stock identification. Fisheries Research, 170, 166–178. The data genetic data collected from port-based sampling of recreationally-landed Chinook salmon in California from 1998-2002.


Data from Magnussen, E. 2011. Food and feeding habits of cod (Gadus morhua) on the Faroe Bank. – ICES Journal of Marine Science, 68: 1909–1917. The data here are Table 3 from the paper, with sample proportions (columns w) multiplied by total weight to yield total grams (g) for each sample-diet item combination. Dashes have been replaced with 0s.


Find appropriate standard deviations for prior


Fit a trinomial mixture model with Stan


Extract estimates of predicted latent proportions.


Extract parameters from fitted model.


Fit a trinomial mixture model that optionally includes covariates to estimate effects of factor or continuous variables on proportions.


Find appropriate prior for a given target distribution.

zoid-package trinomix

The 'zoid' package.