Anomalous behaviour in the layer halides and oxyhalides of titanium and vanadium: a study of materials close to delocalisation