I've poured through the forums several times and have almost found a good solution.
I want to fit a sine wave to some under-sampled constant-frequency/phase/amplitude data. I have hundreds of data files so I need to automate it. I have used SineFit in the file exchange, and it works well most of the time, but has a tendency not to converge. I have also tried sinfapm, but the phase it gives never lines up.