Correction to: Nature Medicine, published online 5 March 2024

In the version of the article initially published, in Fig. 4b, c and Extended Data Fig. 7a, an older version of the data was used during figure preparation. In Extended Data Fig. 6, the cluster labels were applied incorrectly due to a coding error. These errors, which were introduced during figure preparation and do not change the findings of the paper, have now been corrected in the HTML and PDF versions of the article. The earlier, incorrect versions of the figures are available for comparison in the Supplementary information accompanying the online version of this amendment.