3D sinusoidal curve

I've been trying to create this for a couple days now, and I'm running out of ideas.

Basically, I need to take a sinusoidal curve and "bend" it around 360° (see attachment).  The curve you see in my attachment was formed by projecting the sinusoidal curve onto the circle, but as you can see, it doesn't produce an even curve at the ends of the sinusoidal curve.

Does anyone have any idea how I might be able to accomplish this?

SolidworksSketching