# PetscRandomViewFromOptions
View a `PetscRandom` object based on the options database 
## Synopsis
```
#include "petscsys.h" 
PetscErrorCode PetscRandomViewFromOptions(PetscRandom A, PetscObject obj, const char name[])
```
Collective


## Input Parameters

- ***A -*** the  random number generator context
- ***obj -*** Optional object
- ***name -*** command line option




## See Also
 `PetscRandom`, `PetscRandomView`, `PetscObjectViewFromOptions()`, `PetscRandomCreate()`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/sys/classes/random/interface/randomc.c.html#PetscRandomViewFromOptions">src/sys/classes/random/interface/randomc.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/sys/classes/random/interface/randomc.c)


[Index of all Sys routines](index.md)  
[Table of Contents for all manual pages](/docs/manualpages/index.md)  
[Index of all manual pages](/docs/manualpages/singleindex.md)  
