Programatically change a Membership Level

Hello, i have the membership plugin installed on my site , and need to programatically change any level within any user.
Is there any funcion that will help me to do so? Or any manual where i can get the info?
I am checking the plugin code, but if someone have a suggestion , im all ears.