Southern cooks have done this for years--used pureed (cooked) sweet potato where Northerners might use pumpkin, such as in pie.
But have you ever tried it in Pumpkin Cake? It works very well. Just make sure you puree the sweet potato very well--you can mix all the wet ingredients in the blender or food processor, just to be sure. I added a sprinkle of cinnamon-sugar on top before baking--sweet potato always tastes good with a bit of extra cinnamon.
Beats putting out a couple of dollars for a can of pumpkin.
(And of course you can do the same thing with any winter squash that you can get to puree smooth.)