For a cosy TV blanket that will be used every day, you'll need a soft, warm, durable yarn that can be washed many times and still look good. If you can't find a yarn that you like at the exact gauge given in the pattern, then it's unlikely that it will matter if your blanket ends up a little bigger or smaller than the pattern.
On the other hand, if you're making a fitted sweater, even one stitch out with your gauge could mean that it doesn't fit the way you're hoping.
The techniques used in the pattern also affect the yarns you can use: changing from a smooth plied to a fuzzy, fluffy yarn might be fine in plain stockinette stitch, but if your pattern calls for intricate cables, then using a fluffy yarn would leave the cables lost in the haze.
Work out what you need in a yarn
Does the item need to be an exact size?
If you want your finished item to end up at the size given in the pattern, then it matters that you work at the specified gauge and that you knit a swatch to make sure you have the right needles.
What is the overall look of the finished fabric?
Drapy — Not all fibers and yarn will produce a fabric that drapes. Silk, bamboo and other viscose fibers lend themselves to designs with a heavy, swinging drape, while cashmere and mohair give a light, airy drape. A lace shawl made with a light, hazy mohair yarn would have a completely different look and feel if you substituted it with weightier silk or cotton.
Sturdy and firm — Wool, cotton and acrylic yarns can all give a firm, sturdy fabric - depending on the gauge that they're knitted at. Items such as bags, dishcloths and outer-wear sweaters won't last if made from delicate fibers like angora or cashmere.
Surface sheen — Smooth fibers like silk, bamboo, viscose and mercerized cotton all reflect light, giving a lustrous sheen. Mohair and cashmere have a less-obvious, but attractive sheen. Unmercerized cotton and wool have a more matte effect.If you love the shine of the garment in the pattern, choose your fiber accordingly.
What techniques are used?
Color-work techniques like fair-isle / stranded knitting and intarsia are best suited to fibers which have some elasticity to help close any gaps and even out the tension inconsistencies. It is possible to use inelastic cotton for intarsia, but for best results and easier knitting choose wool or acrylic.
Textured stitches, such as seed stitch (moss stitch in the UK) or cables are best shown off with a smooth, plied yarn. The texture would be lost in the haze of a highly fuzzy yarn, and even a tweedy yarn would disrupt the clean lines. As with all things knitting, you can choose to do something different and use a fancy yarn for a cabled pattern, but think about the effect that it will have on the final look of the finished work.
Ribbing can provide shaping to a garment as the columns of knit and purl stitches pull in towards each other. The fiber you use has an important effect on how effectively the ribbing pulls in, and whether it continues to do so after being washed and blocked. Ribbing worked in wool will pull inwards strongly, acrylic, alpaca and cashmere less so, cotton even less and the inelastic silk and linen won't pull in at all. If shaping in your chosen design is achieved through ribbing, then imitate the designer's yarn choice as closely as you can.
Does the design rely on a fancy / novelty yarn?
If the interest in your garment is provided, for example, by a slubby/thick and thin textured yarn, or an eyelash yarn, then you need to pick a yarn with the same texture.
Will it be worn against the skin?
People's tolerance to wool against their skin differs widely. While some can wear a scratchy Shetland shawl around their neck without flinching, others can barely tolerate holding it in their hands. The prickle factor depends on the diameter of the individual fibers in the yarn. Very fine Merino wool and luxury yarns like cashmere and camel get their softness from the small diameter of the fibers. Alternatively, choose plant fibers, silk or acrylic to reduce the prickliness.
Will it be subject to heavy use?
Some fibers are more durable than others. Generally the finer and shorter the length of the individual fibers, and the less tightly the yarn is plied, the more easily unattractive balls or 'pills' of fiber will work their way out of the fabric and sit on the surface. Items like socks, which are heavily used, last much longer if knitted at a tight gauge and reinforced with a percentage of a durable fiber like nylon.
Do you want it to feel particularly warm or cool?
In general, animal fibers feel warm and plant fibers (cotton, bamboo, linen, hemp) feel cool. Fibers like wool and silk can do both, keeping you warm when it's cold and cool when it's warm! Yak, bison, angora and camel are amongst the warmest of the fibers.
Garments made from man-made fibers such as acrylic, polyester and nylon are not good at allowing moisture to escape and can feel hot and clammy as a result. If you're looking to substitute a cool fiber for a warm one, or vice versa, keep in mind the differences in drape and elasticity between plant/silk and animal fibers. A fifty/fifty blend of cotton and wool might be a good compromise, as this brings characteristics of both fibers to the finished item.
Are there any ethical considerations for you or the person you're making it for?
You may prefer to work with organic cotton, natural fibers, or locally grown and spun yarns for example.
Is there a budget limit?
Yarn can be very pricey, especially if using the finest quality fibers, or if manual labor is involved in its production. There's often a less expensive yarn that can work as a reasonable substitute though.
Find a substitute
If you're looking for a direct alternative to a yarn, YarnSub can give you a list of the closest substitutes. If you're thinking of changing to a different fiber, you can use YarnSub's search capability to find possibilities.
Example: Finding a non-wool alternative
Let's say you're looking for a non-wool substitute for Debbie Bliss Rialto Aran.
Lookup the gauge and texture — Rialto Aran has a plied texture and a gauge of 18 sts / 10cm.
Search for alternatives — Type: plied 18 sts not wool into the YarnSub search box, and you'll be offered a list of possibilities. If you don't want to use acrylic either, then type: plied 18 sts not (wool or acrylic)
Following the links above will take you to the list of yarns that YarnSub has found in each case.
Swatching is your chance to experiment and reduce the uncertainty surrounding your project. A swatch is like an informal get-together between you, the yarn and the needles or hook, to decide if you want to work together. You're going to spend days, weeks, even months in each other's company. Invest an hour finding out if you're compatible first!