I'd like to move a WP installation from a subdomain to its own without losing the PageRank achieved by that subdomain.
What are the best steps in order to do this properly? Especially how do I set the redirects properly?
Follow these instructions on moving WordPress, but use the root domain for references to your old subdomain instead of the /blog/ directory (I've made this change for you in the steps below):
To keep your PageRank, the crucial step is step 7, which redirects requests for your old blog pages to the new site.