# Simulate data
df <- simulateData(n.entity = 100, n.obs = 80, mu = 0.2, r = 0.6, beta1 = log(1.6))
# Calculate risk-adjustment model performance
model.perf <- model_performance(df = df, model = 'y ~ x1 + (1|entity)')
# Calibration plots
plotCalibration(model.perf)
plotCalibration(model.perf, quantiles = 5)
Run the code above in your browser using DataLab