I realize this is an old thread, but I hit this query on google recently.
Here's how you do it:
$command = "Get-Process" Invoke-Expression $command
Anything in your $command string will be invoked just like the user had written it.