The answer, I believe, is the 4HJ2-HTE is the slightly older version, and the 4JH3-TE is the slightly newer version....many of the "bolt-on" parts
are interchangeable, like oil
filters, belts, etc..
But some (most?) internal parts
are different (a subscription to boatdiesel.com would get you many answers)
I have a 4JH2-HTE (a 1999 model, with about 1800hrs) and she starts INSTANTLY (never needs to "crank", just "bump" the starter button and she's running), and purrs along just beautifully....(although, when cold she takes about 3 minutes to idle perfectly smooth, that's rare in warm / tropical climes).
I have friends with sister-ships, with the newer version (4JH3-TE) and they have similar stories, of love for their Yanmar
....(although they have an "electric" stop button, and I have the simple "pull-cable" stop / fuel-shut-off, and I prefer the old-fashioned pull-cable stop.)
Personally, I've found Yanmar's to be wonderful engines, and if you change the oil/filter regularly, feed them clean fuel
(change Racor's regularly), they will run and run....and you're more likely to sell the boat
before ever needing a rebuild
As to your exact question (which one is more desirable)??
I'd pick the one that is better maintained, and/or has less hours...
But, to be clear, I'd pick the boat
that has been better maintained and/or less "used", and the actual engine
hours would be down my list of criteria a bit...
As long as you stay away from the "modern" hi-pressure common-rail injection engines, you should be fine.
I hope this helps.