Summarize the following:
Ensure that the water supply is off before removing the valve. Affix a pipe wrench to the 6-sided nut that holds the valve body in place. Rotate it counter-clockwise to loosen it from the valve body.  The compression nut is a ring that fits around the pipe. After loosening it from the valve body, you can slide it down the pipe shaft and remove the valve. You'll follow this step only if your existing valve uses a compression fitting. If you're replacing a threaded or sweat valve with a compression valve, you'll need to cut the soldered or threaded end of the pipe before you install the new valve. With the compression nut loosened, simply pull the old valve off of the pipe. Locate the compression sleeve, which is a ring that fits snugly at the end of the pipe. Use pliers to carefully rotate it and remove it from the pipe, then slide off the compression nut. Don't use too much pressure with the pliers. If you warp the pipe, it won't receive the new valve. If you can't remove the ring with pliers, cut it carefully with a small hacksaw. Insert a flat-head screwdriver into the slice you made in the ring, then twist the screwdriver to widen the ring. Pull the ring off the pipe, then slide off the old compression nut. Cut with finesse and make sure you don't cut through the ring into the pipe. If you're replacing a sweat or threaded valve with a compression valve, use a hacksaw to cut off the soldered or threaded end of the pipe. Cut slowly and carefully to avoid warping the pipe. Sand away rough edges with emery cloth when you've finished cutting. Make sure you leave enough pipe to hold the new fitting. Depending on the size of your new valve, you'll probably need at least 2 inches (5.1 cm). You'll need to remove piping at both ends if you're replacing a 2-way valve (as opposed to a pipe that comes out from a wall and feeds a faucet or toilet). If the pipes are old, corroded, or soldered onto the valve, cut each pipe just past where they connect to the valve. If the pipes connect to a 2-way valve with compression fittings, just loosen each compression nut. Make sure the threaded end of the new nut faces out so it can receive the new valve. Slide it all the way down the pipe so you have some room to work. Then place the new compression sleeve over the end of the pipe. The compression sleeve, or ferrule, needs to fit snugly. It creates a watertight seal between the valve and the pipe. If you purchased a valve that matches your pipe's diameter, the compression sleeve will be snug. Place the valve on the end of the pipe, then pull the compression nut down the pipe's shaft to the threaded end of the valve body. Rotate the nut clockwise by hand, then use a pipe wrench to finish tightening it. If you're replacing a 2-way valve, tighten the compression nuts on both ends. If your valve feeds a faucet, toilet, or other fixture, replace the supply lines that lead from the valve to the fixture. Start them off by hand, then finish tightening them with the pipe wrench. Make sure they're not so tight that it's impossible to remove them in the event that they need service in the future. Make sure you've turned off the faucets you turned on to drain the system, then turn on your home's water supply. Head back to the valve you replaced and check for leaks. If you spot a leak, tighten the compression nut.
Loosen the compression nut by turning it counter-clockwise. Remove the old valve and compression sleeve. Cut the old compression sleeve if it's stuck. Cut an old soldered or threaded supply pipe, if necessary. Loosen or cut the pipes on each side of a 2-way valve. Slide the new compression nut and sleeve onto the supply pipe. Thread the valve into the compression nut. Reattach supply lines, if necessary. Turn on the water supply and check for leaks.