#include "petscdraw.h" #include "petscsys.h" #include "petscviewer.h" PetscErrorCode PetscDrawHGCreate(PetscDraw draw,int bins,PetscDrawHG *hist)Collective on PetscDraw
draw | - The window where the graph will be made | |
bins | - The number of bins to use |
Notes: The difference between a bar chart, PetscDrawBar, and a histogram, PetscDrawHG, is explained here http://stattrek.com/statistics/charts/histogram.aspx?Tutorial=AP
The histogram is only displayed when PetscDrawHGDraw() is called.
The MPI communicator that owns the PetscDraw owns this PetscDrawHG, but the calls to set options and add data are ignored on all processes except the zeroth MPI process in the communicator. All MPI processes in the communicator must call PetscDrawHGDraw() to display the updated graph.