Can I call a C++ function in editor and save the results?

I have a custom node based pathfinding system. Collections of these nodes are stored per room in an array per their respective overlapping room class. Currently I am creating these arrays at Begin play. I would like to be able to get all of the overlapping nodes for each room and then store them in arrays that get saved along with the map and the Room actor. How could I implement a button to execute my begin play c++ function in the editor?