I used data from the biodiversity monitoring program where 615 key habitats have been surveyed by experts at the Swedish Forest Agency with regards to stand factors and species. Landscape data was downloaded form SLU, the Swedish forest Agency as well as the Swedish Environmental Protection Agency. To analyse what stand and landscape factors that determine the species richness, I used a Bayesian joint species distribution model.