Total: 1
Bayesian inference is commonly employed in the analysis of gravitational-wave signals not only to estimate the source parameters, but also for model selection. The latter provides insight into the physics of the source and has the potential to inform the direction for future model development. Although model comparison is usually performed by analyzing the data separately with different models and comparing the obtained Bayesian evidences, an alternative approach consists in sampling directly over the model itself. Here, we present t-roo, a reversible jump Markov chain Monte Carlo sampler capable of performing transdimensional inference on gravitational-wave signals from compact binary coalescences. Employing t-roo, a single analysis provides simultaneously the model odds ratio and the parameter posteriors for the favored models, hence yielding a potentially substantial computational advantage, particularly when comparing many models or analyzing highly informative data. t-roo is built on the sampler eryn and is specifically designed to compare models describing different kinds of sources, i.e., binary black hole, binary neutron star, or neutron star-black hole systems, as well as multiple models for the same source class. We validate the sampler on a set of injections, finding agreement with the results obtained with the nested sampler dynesty. We then use t-roo to analyze the real events GW190425 and GW230529, for which the system's parameters alone do not provide conclusive evidence of the presence of a neutron star component. t-roo can be adapted to any model-comparison scenario, thus providing a valuable tool in particular for next-generation detectors, where analyzing data separately with competing models becomes computationally even more demanding.