Here is Canvas object wihch demonstrate the problem.
Shear stress in a flanged shape

The maximum transverse shear stress for the wide-flange shape will occur at the neutral axis. Therefore, the calculation of Q is based on the area comprising the upper half of the shape. The moment of this area about the z axis must be computed.