Something like that was going on with my desktop PowerMac. It went away when I got a new mouse.
That's not so easy to do with a laptop. But you might try an add-on mouse.
Do you use two hands to operate the trackpad/ball/stick? My sister has a laptop with metallic surfaces. The trackpad picks up the voltage differential between the two hands. This fools the cursor. Makes it jump around. So we have to use one hand on the trackpad.
It would be easy to suggest de-installing and re-installing the trackpad driver. Or keyboard driver. However if it doesn't work then you might have nothing.
What if your Home key or Page-Up key is stuck? Try tapping them a few times. It might loosen any stickiness, or a rogue whisker connecting the electrical contacts.
If you need to, you can switch between icons (menu items, buttons, etc.) by pressing the Tab key. Press Return to select the highlighted item.