Store observed data in arviz

In Bayesian Hierarchical Linear Regression — NumPyro documentation I can see that the inference data is imported to arviz using data = az.from_numpyro(mcmc).

When displaying that object, I can see the data set observed_data and it includes the variable obs.
And I assume this is because of numpyro.sample("obs", dist.Normal(FVC_est, σ), obs=FVC_obs)

My question is how I can store other inputs, like Weeks in this model.
I really want to include that into the arviz data, so I can make plots directly from that object, using both Weeks & FVC_obs

Hi @mattiasthalen, I guess you can store other inputs using arviz.InferenceData.add_groups method.

Nothing in the model?
With PyMC you can capture the inputs via pm.Data()

If you want to store something in the trace, you can use deterministic primitive I guess. I’m not sure about the motivation of storing data in the model though. In NumPyro, data comes from either function input or local/global constants.