Can a bad knock sensor and oxygen sensor cause a shudder? on 2000 Nissan Pathfinder

I recently bought a 2000 Nissan pathfinder. The service engine soon light came on as I was driving. The codes ran as a knock sensor and oxygen sensor in bank 1 and bank 2, high voltage. I notice around 35 mph the engine or transmission shudders. The car sat on the lot for a couple of months, so my first reaction was old gas. I filled it up with plus after running all of the old gas out and adding sea foam. Does this sound like a transmission problem or could a knock sensor be causing the shudder? The car switches between gears at low speeds without problems, including taking off.

Asked by for the 2000 Nissan Pathfinder
Does it only 'shudder' under light throttle? If so , it may be internal trans problem. Best would be to have a trusted shop test drive it WITH you to confirm the symptom , and go from there. Maybe check with Nissan for any related service bulletins that may help.
It tends to shudder after it has shifted smoothly. The knock sensor code is showing a detonation code. Could this be affecting it? Or the ignition timing?
Knock sensor helps the PCM determine the right amount of spark advance. STILL recommend having it diagnosed , even if it's something that you decide is not worth bothering with. This way at least you'll know if it's a good time to sell?