# calibrateItems

0th

Percentile

##### Determine the optimal scale constant for a set of items

Data are passed through filterGraph and normalizeData. Then the ‘unidim_adapt’ model is fit to each item individually. A larger varCorrection will obtain a more accurate scale, but is also more likely to produce an intractable model. A good compromise is between 2.0 and 4.0.

##### Usage
calibrateItems(df, iter = 2000L, chains = 4L, varCorrection = 3,
maxAttempts = 5L, ...)
##### Arguments
df

a data frame with pairs of vertices given in columns pa1 and pa2, and item response data in other columns

iter

A positive integer specifying the number of iterations for each chain (including warmup).

chains

A positive integer specifying the number of Markov chains.

varCorrection

A correction factor greater than or equal to 1.0

maxAttempts

How many times to try re-running a model with more iterations.

...

Additional options passed to stan. The usual choices are iter for the number of iterations and chains for the number of chains.

##### Value

A data.frame (one row per item) with the following columns:

item

Name of the item

iter

Number of iterations per chain

divergent

Number of divergent transitions observed after warmup

treedepth

Number of times the treedepth was exceeded

low_bfmi

Number of chains with low E-BFMI

n_eff

Minimum effective number of samples across all parameters

Rhat

Maximum Rhat across all parameters

scale

Median marginal posterior of scale

thetaVar

Median variance of theta (latent scores)

##### References

Vehtari, A., Gelman, A., Simpson, D., Carpenter, B., & B<U+00FC>rkner, P. C. (2019). Rank-normalization, folding, and localization: An improved $\widehat R$ for assessing convergence of MCMC. arXiv preprint arXiv:1903.08008.

check_hmc_diagnostics

##### Aliases
• calibrateItems
##### Examples
# NOT RUN {
result <- calibrateItems(phyActFlowPropensity)  # takes more than 5 seconds
print(result)
# }

Documentation reproduced from package pcFactorStan, version 0.11, License: GPL (>= 3)

### Community examples

Looks like there are no examples yet.