When you had to split something as a kid, that generally didn't feel like a perk. But when you're an investor, splitting can be a good thing.

Stock splits are a way a company's board of directors can increase the number of shares outstanding while lowering the share price. They are a tactic for making a stock more attainable to smaller investors, particularly when its price has ratcheted sky-high over time.

While neither the company's value nor that of your investment changes in a split, it's important to understand how stock splits can impact your portfolio.

Stock splits are accompanied by somewhat confusing arithmetic, such as "2-for-1" or "3-for-2." As with many things in life, pizza can help.

Imagine a company's value represented by an entire pizza. For simplicity's sake, let's say the pizza was divided into eight slices and you owned one share.

If a company announces a 2-for-1 split, the number of shares doubles, so the original pie will be divvied up into 16 slices. Whereas you owned one-eighth of the company before, as a result of the split you will now own two-sixteenths. Same amount of pizza, just more slices.

The company's market capitalization, equal to shares outstanding multiplied by the price per share, isn't affected by a stock split. If the number of shares increases, the share price will decrease by a proportional amount.

However, investors generally react positively to stock splits, partly because these moves signal that a company wants to attract investors by lowering the price.

In 1997, 102 companies in the S&P 500 — or about 1 in 5 members of the index — did a stock split. The tally was eight last year, and through early July of this year, it was only three, according to S&P Dow Jones Indices.

Stock splits have fallen out of favor as companies and investors alike have become accustomed to higher stock prices, industry analyst Howard Silverblatt says. "That said, some boards still have a trading range for their issues, and given the current levels, I would expect more stock splits once uncertainty drops."

Even though the biggest companies aren't splitting today, that doesn't mean you won't encounter a split. If a stock or ETF in your portfolio splits, don't make a knee-jerk decision that you may regret down the road.

Instead, decide whether your original investment premise has changed as a result — or revisit your stock strategy now. If it hasn't, your best bet may be to sit tight.

Anna-Louise Jackson is a staff writer at NerdWallet, a personal finance website.