According to Lee's volume density chart, HP38 has a density factor of .09260. W231 is .09310. to use these factors, you multiply your desired charge weight by the density factor, giving you the volume in cubic centimeters (CC).
So, if you want to find the volume measurement for 5 grains of either powder the math would be 5 X .09260= .463. So slightly less than a .5 CC Lee dipper. or, 5 X .09310=- .4655. also a short hair less than a .5 CC dipper.
Not exactly the same, but close enough for horseshoes. Lee's data is reputed to be on the light side for safety's sake, but their density conversions are said to be inaccurate, so take warning and check your dipper against a scale.
FWIW, I have used a few volume conversions with mixed results downrange. My 9mm likes a load developed using this method, but I tweeked it with a scale and now it likes it even better.
Happy dipping!