Bayz Manual

Summaries with pbayz

The first and simplest way to summarise the sample output in parameter estimates, is to compute the mean (posterior mean) and standard deviation (posterior SD) of the saved samples. The tool 'pbayz' is supplied with the executables, and can do this for different sets of parameters in the output. 

pbayz is a command-line tool, use it for instance on a linux prompt, in the directory with output from a bayz model run. Note: the standard pbayz call only makes a "short summary" which only shows part of the estimates, use additional options as shown below to get more or different output. An example run for a bayz job that was called "ranreg.bayz":

lucj$ pbayz ranreg
   pbayz (1.1) summary showing parameters with up to 25 levels
   parameter            label                                   post.mean           post.stdev
   var.resid.phen1      var.resid.phen1                         0.610262            0.0299172
   mean.phen1           mean.phen1                              14.5155             0.00500941
   var.reg.snp.phen1    var.reg.snp.phen1                       0.00162711          0.0010864

   This summary is also saved in ranreg.plog
lucj$
In this case, pbayz has decided to report estimates for 2 variance components and a mean for its "short summary". As reported, the summary is also saved in a file with extension .plog for later reference.

Additional pbayz options:

pbayz can be instructed to produce more than just the "short summary" by adding extra options as shown below. For jobname give the name of the bayz script file, without .bayz extension.

  1. pbayz jobname: will produce a summary of main model parameters, by selecting all parameters with up to 25 levels (the 25 can be modified as explained in version 2 and 3 below). This will typically pull out estimates for means, variances, low-level factors and (single) regressions. The command produces a screen output with the parameter estimates, but also saves the estimates in a file jobname.plog.
  2. pbayz jobname maxlev=50: as version 1, but increases the selection of parameters to retrieve to those with upto maxlev parameters.
  3. pbayz jobname maxlev=0: produces a summary of all parameters estimates (potentially a large file, summary is not shown on screen).
  4. pbayz jobname table: will format the output differently with the parameter name repeated in all lines of the first column; this provides a format that can be easier to work with in R or spreadsheets.
  5. pbayz jobname par=polyg.mouse.weight: retrieves estimates for the indicated parameter (regardless of size). Parameter names are as in the model section of the bayz job file. This command does not show the parameter estimates as screen output, but saves the estimates in the file jobname.plog.
  6. pbayz jobname par=polyg.mouse.*: can retrieve estimates for multiple parameters, for instance in multi-trait models. The wildcard can be placed anywhere, for instance par=polyg* would also have worked (unless there are polyg terms which are not polyg.mouse). Or when there are traits Weight10, Weight15, Weight20, par=polyg.mouse.Weight1* would match the polygenic effects for Weight10 and Weight15, but not Weight20.
  7. pbayz jobname par=polyg.mouse.* table: as 5, but will (attempt to) format the output in table format, with the different parameter sets presented column wise. This will only work when every parameter has the same number of levels. 

Notes: