Heat iron skillet (or nonstick skillet) over medium heat with enough olive oil to coat the bottom. Let warm for a few minutes. You don't want to throw your sweet potatoes into a cold skillet with cold oil - it should sizzle a little bit.
Add sweet potatoes and stir around a little to coat in the oil. Let cook untouched for about 5 minutes. Then give them a toss, bottoms should be a little browned, and cook another 5 minutes. Add additional oil in needed to keep them from sticking.
Add onion and apple, cook 4-5 minutes until everything is tender and the sweet potatoes are browned.
Stir in butter if using, give a toss to melt it and coat everything. Season with salt and pepper to taste and serve.