Anatomical defences against bark beetles relate to degree of historical exposure between species and are allocated independently of chemical defences within trees.