Diagram creation is more generic now and supports both Sample and Subject