Chris,
My dnaLinearFit script only works on monochrome data at the moment, that might be part of the problem. I would go with Mike's suggestion for now, which you can do easily with PixelMath like this, where ref is the reference image:
iif($T>0, ((mean(ref)-med(ref))*$T + mean($T)*med(ref) - mean(ref)*med($T))/(mean($T)-med($T)), 0)
This uses the mean and median of two images as points on a line and adjusts the target image so that it's mean and median match the reference. This is what my script does in mean/median mode, except that it only uses the pixels that are non-zero in both images to determine the mean and median of each. It's that last part that makes my script useful for mosaics. It also keeps pixels with a value of zero as zero which GMM needs.
I will update my script to handle color channels soon.
Regards,
David