I had a customer come in because the sweater she had just knit was already pilling. So how do you tell before you start a project whether it will pill or not? The first thing you can look at in the yarn is how many plies there are. The more plies the less likely the yarn is to pill. The looser the twist the more likely the yarn is to pill. So a single ply with a loose twist is probably going to pill, whereas a multiplied yarn with a tight twist will be less likely to pill.
The next thing to look at is how much halo there is to the yarn. Halo is the amount of fibre or fluff you can see in the yarn ball. The more fluff there is the more likely it is to pill, especially if you can pull the fluff off easily.. If you can see a halo in the ball, you will see the halo in the garment.
Cotton, silk and linen are less prone to pilling than is wool. Acrylics are also prone to pilliing. Often the cheaper the acrylic the more likely it is to pill. There are acrylic yarns which are labelled as anti pilling and those are good ones to choose. Microfibres tend to pill easily as well. Make sure you follow the washing instructions on the yarn label to help prevent pilling. If you use yarns that have some cotton, silk or linen in them that will help lessen the pilling problem.
The areas where pills usually show up are in the areas where there is more wear in the garment. This means areas like the underarms will be more prone to pilling. At least this is an area where it won’t be very visible.
The best way to tell how a yarn is going react is to knit a test swatch and wash it. Rub the fabric together and see if you get any pills forming. If you don’t want to do a swatch you could try carrying a couple balls of the yarn around in a bag where they can rub together and see if you see any signs of pills starting on the balls.
You can purchase sweater shavers and special pumice stones to remove pills from your knitted garments. Try not to pull or remove them with a razor as you may damage the yarn in the rest of the garment. If you take good care of your knitted garments they should last for years even if they do develop a few pills over the years.