class_docstr: A basic class for Principal Component Analysis (PCA).
  
  p is the number of dimensions, while N is the number of data points
docstr: projects the normalized values onto the components
  
  enthresh, nPCs, and cumen determine how many PCs to use
  
  if vals is None, the normalized data vectors are the values to project.
  Otherwise, it should be convertable to a p x N array
  
  returns n,p(>threshold) dimension array
docstr_tok: ["projects","the","normalized","values","onto","the","components","enthresh",",","nPCs",",","and","cumen","determine","how","many","PCs","to","use","if","vals","is","None",",","the","normalized","data","vectors","are","the","values","to","project",".","Otherwise",",","it","should","be","convertable","to","a","p","x","N","array","returns","n",",","p","(",">","threshold",")","dimension","array"]
code: def project(self, vals=None, enthresh=None, nPCs=None, cumen=None):
      """
      projects the normalized values onto the components
  
      enthresh, nPCs, and cumen determine how many PCs to use
  
      if vals is None, the normalized data vectors are the values to project.
      Otherwise, it should be convertable to a p x N array
  
      returns n,p(>threshold) dimension array
      """
      nonnones = sum([e is not None for e in (enthresh, nPCs, cumen)])
      if nonnones == 0:
          m = slice(None)
      elif nonnones > 1:
          raise ValueError("cannot specify more than one threshold")
      else:
          if enthresh is not None:
              m = self.energies() > enthresh
          elif nPCs is not None:
              m = slice(None, nPCs)
          elif cumen is not None:
              m = np.cumsum(self.energies()) < cumen
          else:
              raise RuntimeError("Should be unreachable")
  
      if vals is None:
          vals = self.N.T
      else:
          vals = np.array(vals, copy=False)
          if self.N.T.shape[0] != vals.shape[0]:
              raise ValueError("shape for vals does not match")
      proj = np.matrix(self.getEigenvectors()).T * vals
      return proj[m].T
  
file_path: statsmodels/statsmodels/sandbox/pca.py
imports: import numpy
label_desc: Use image node_id 12 for calling the Pca obj's underlying member method code with example usage: obj.project(vals, enthresh, nPCs, cumen) and returns: proj