all comp/hist adding code now tested