Yarn substitution is becoming more common as the Internet impacts pattern purchasing through digital downloads. Yarn companies are developing new yarns and the indie dyers and hand spinners are adding new yarn sources as well. It's becoming more common for knitters to be unable to find the exact yarn used in the pattern in their LYS (if they even go to one as many buy yarn online as well).
When I was a yarn store employee we often used the standard of stocking stitch gauge for yarn substitution. Gauge can work well, especially when you know the named weight of a yarn, for example worsted. More recently it seems that ball bands are getting vaguer rather than more precise. I now find DK yarns listed with gauges of 20 to 24 stitches to 4 inches. In the past DK was normally labelled as 22 stitches. This stretches the possible weight from sport to worsted if you are using the Craft council weight system. Add to this the variety of fibres being produced in DK weight and the impact each has on the end result. Spinning techniques have their own unique qualities that may change the performance of individual yarns. Suggested needle size has also become a range instead of a single needle size. I think these changes are good as experienced knitters know we don't all knit in the same way and get the same results, however it makes thing more difficult for the novices.
I now have added another comparison factor I use for yarn substitution. I do a yardage/metre to ounces/grams ratio calculation. Just divide the length by the weight. The resulting ratio will allow you to more closely match yarns especially if you have the same fibre content information and ply information. As an aside, have you noticed the imperial and metric systems are getting crossed with yardages quoted by grams?
All yarns below are all DK 100% wool plied yarns. The ratios are the yards divided by the grams. The type of wool fibre used for each could vary, unless the label tells us we don't know the source breed. One is superwash and the gauges listed are not all the same.
GGH Wollywasch: Ratio 2.5, 22.0 sts = 4 inches
Rowan Pure Wool DK: Ratio 2.84, 22.0 sts = 4 inches
4 Seasons Pure Wool Printed 8 Ply: Ratio 1.74,Drops Karisma Classic: Ratio 2.4, 21.0 sts = 4 inches or Drops Karisma Superwash; Ratio 2.18, 20 - 22.0 sts = 4 inches
22.0 sts = 4 inches
22.0 sts = 4 inches
I'd think carefully and do a large swatch if I wanted to substitute 4 Seasons for Karisma Classic. If I went from from Woolywasch to Drops Karisma Classic I'd be much less concerned.