title: How can I view the source code for a particular `predict` function?
body: <p>Based on the documentation, <code>predict</code> is a polymorphic function in <code>R</code> and a different function is actually called depending on what is passed as the first argument.</p>
  
  <p>However, the documentation does not give any information about the names of the functions that <code>predict</code> actually invokes for any particular class.</p>
  
  <p>Normally, one could type the name of a function to get its source, but this does not work with <code>predict</code>.</p>
  
  <p>If I want to view the source code for the <code>predict</code> function when invoked on objects of the type <code>glmnet</code>, what is the easiest way?</p>