Wall paneling, whether it's plywood sheet or wood plank, must sometimes be trimmed to fit against a stone wall or other irregular surface. Create a tight fit by using a pencil compass to scribe the wavy, irregular edge onto the paneling.
Start by holding the plank or plywood sheet against the wall. Check it for plumb with a level to be sure it's perfectly vertical, then temporarily tack it in place. Set the compass to the widest gap between the paneling and the wall, then hold it with its metal pivot point against the irregular surface and its pencil point on the paneling. Slide the compass down so the pencil transfers the profile of the irregular edge onto the paneling. Then cut the paneling along the wavy line using a sabre saw fitted with a narrow scrolling blade. If necessary, use a coarse half-round file to trim any high spots off the paneling so it fits tightly against the wall.