Functions like optim(par,f) require "par" to be a vector and "f" to be a function of a vector. Often you'll want to optimise a cost function with several arguments, for example a scalar, a vector and a matrix, and it's more natural to define f = function(scalar,vector,matrix) instead of packing everything into a single vector. vecpack does the packing and unpacking for you.
Package details 


Author  Simon Barthelme <[email protected]> 
Maintainer  Simon Barthelme <[email protected]> 
License  GPL 
Version  0.1 
Package repository  View on GitHub 
Installation 
Install the latest version of this package by entering the following in R:

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.