Reading cmdstanr csv files

Hi everyone,

Sorry if this is an obvious question but I wasn’t able to figure it out from the cmdstanr website.

I ran a big model for about a week but the machine got shut down before I could look at the samples. I ran two chains and all I have left is the .csv files that get saved when specifying the argument output_dir in sample(). Is there any way I can use those .csv files to inspect my posterior draws?

Thanks!

Matt

You can use the ”stansummary" utility from the cmdstan binaries directory.

If your .csv files contain the complete posterior estimates from a model, you can try:

cmdstanr::as_cmdstan_fit(path_to_files)