title: Create a numeric vector with names in one statement?
body: <p>I'm trying to set the default value for a function parameter to a named numeric.  Is there a way to create one in a single statement?  I checked ?numeric and ?vector but it doesn't seem so.  Perhaps I can convert/coerce a matrix or data.frame and achieve the same result in one statement?  To be clear, I'm trying to do the following in one shot:</p>
  
  <pre><code>test = c( 1 , 2 )
  names( test ) = c( "A" , "B" )
  </code></pre>