class_docstr: A univariate random variable.
class_docstr_tok: ["A","univariate","random","variable","."]
docstr: Sample from a univariate distribution.
  
  Parameters
  ----------
  point : array-like, shape=[..., *space.shape]
      Point representing a univariate distribution.
  n_samples : int
      Number of points to sample with each pair of parameters in point.
      Optional, default: 1.
  
  Returns
  -------
  samples : array-like, shape=[..., n_samples, *support_shape]
      Sample from distribution.
docstr_tok: ["Sample","from","a","univariate","distribution",".","Parameters","--","--","--","--","--","point",":","array-like",",","shape=","[","...",",","*","space.shape","]","Point","representing","a","univariate","distribution",".","n_samples",":","int","Number","of","points","to","sample","with","each","pair","of","parameters","in","point",".","Optional",",","default",":","1",".","Returns","--","--","--","-","samples",":","array-like",",","shape=","[","...",",","n_samples",",","*","support_shape","]","Sample","from","distribution","."]
code: def rvs(self, point, n_samples=1):
      """Sample from a univariate distribution.
  
      Parameters
      ----------
      point : array-like, shape=[..., *space.shape]
          Point representing a univariate distribution.
      n_samples : int
          Number of points to sample with each pair of parameters in point.
          Optional, default: 1.
  
      Returns
      -------
      samples : array-like, shape=[..., n_samples, *support_shape]
          Sample from distribution.
      """
      batch_shape = get_batch_shape(self.space.point_ndim, point)
      n_points = math.prod(batch_shape)
  
      pre_flat_shape = batch_shape + (n_samples,)
      params = self._flatten_params(point, pre_flat_shape)
  
      size = n_points * n_samples
      flat_sample = gs.from_numpy(self.scp_rvs(**params, size=size))
  
      expected_shape = (
          batch_shape + (n_samples,) + self.space.support_shape
      )
      return self._unflatten_res(flat_sample, expected_shape)
  
imports: import math
  import geomstats.backend
  from geomstats.vectorization import get_batch_shape
label_desc: Use image node_id 2 for calling the ScipyUnivariateRandomVariable obj's underlying member method code with example usage: obj.rvs(point, n_samples) and returns: self