Work better for what?
I have a good amount of experience with both, including being on rowing team and cycling club during college. As sushiritto notes, a rower puts far more stress on the back than a cycling machine. This can be a good thing or bad thing, depending on whether you are trying to stress or avoid stress on your back, following the surgery. Your answer might depend on how the recovery progresses. For example, you might prefer to initially work your back in a well controlled manner as part of the PT and be able to go high intensity in cardio, without being limited by your back. Or if you are well recovered, you might want to stress your back as part of your usual exercise.
Regarding stationary bike vs Peloton, the best exercise choice is often the one that you’ll stick with, without quitting. If a Peloton helps you stick with it, that would likely work better. However, it’s certainly not the case that everyone is more likely to persist with a Peloton than working out on their own. I certainly wouldn’t. You might think about why you stopped using the stationary bike and rower that you already own. Would the Peloton help with, whatever reasons you stopped working out in the past?
I personally find that indoor workouts are more enjoyable when I watch TV during the exercise, which can be another option. When I was in college, I’d push this even further and read while on the stationary bike, including reading textbooks from my classes. Getting in a habit of doing something I enjoyed while cycling, helped pass the time and made the exercise more enjoyable.