# Particle Density Plot

**URL:** https://discourse.paraview.org/t/particle-density-plot/6417
**Category:** ParaView Support
**Created:** [February 8, 2021, 2:11pm UTC](https://discourse.paraview.org/t/particle-density-plot/6417 "2021-02-08T14:11:14Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![WEsToMIL](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/w/e47774/32.png) [@WEsToMIL](https://discourse.paraview.org/u/WEsToMIL)
#### Post date: [February 8, 2021, 2:11pm UTC](https://discourse.paraview.org/t/particle-density-plot/6417/1 "2021-02-08T14:11:14Z")

</div>

Hi

I’m looking for a way to plot the particle density of a simulation along a single dimension. Basically a histogram of the y-coordinates. At a first glance the histogram filter looks just like the thing I need, however, it only lets me use the particle properties as input but not the particle coordinates. What do I have to do pass the y-coordinates to this filter? Or do I have to use a different one?

Here is a dummy version of my data files to show their layout:

```auto
<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<VTKFile byte_order="LittleEndian" type="UnstructuredGrid" version="0.1">
  <UnstructuredGrid>
    <Piece NumberOfCells="0" NumberOfPoints="2">
      <PointData>
        <DataArray Name="PropA" NumberOfComponents="1" format="ascii" type="Int32">0 1</DataArray>
        <DataArray Name="PropB" NumberOfComponents="1" format="ascii" type="Int32">2 3</DataArray>
      </PointData>
      <CellData/>
      <Points>
        <DataArray Name="points" NumberOfComponents="3" format="ascii" type="Float32">0.0 0.0 0.0 1.0 1.0 1.0</DataArray>
      </Points>
      <Cells>
        <DataArray Name="types" NumberOfComponents="0" format="ascii" type="Float32"/>
      </Cells>
    </Piece>
  </UnstructuredGrid>
</VTKFile>

```

---

<div class="post-metadata">

### Author: ![nicolas.vuaille](https://discourse.paraview.org/user_avatar/discourse.paraview.org/nicolas.vuaille/32/5873_2.png) [@nicolas.vuaille](https://discourse.paraview.org/u/nicolas.vuaille)
#### Post date: [February 8, 2021, 2:21pm UTC](https://discourse.paraview.org/t/particle-density-plot/6417/2 "2021-02-08T14:21:47Z")

</div>

Indeed, it is something missing …

You can work around with the calculator:

- Load your data
- Create a Calculator
- Specify `coordsY` as formula
- Create Histogram

The y-coordinate is now available as the `Result` Array.

---

<div class="post-metadata">

### Author: ![WEsToMIL](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/w/e47774/32.png) [@WEsToMIL](https://discourse.paraview.org/u/WEsToMIL)
#### Post date: [February 8, 2021, 2:33pm UTC](https://discourse.paraview.org/t/particle-density-plot/6417/3 "2021-02-08T14:33:46Z")

</div>

It feels like the calculator step should not be necessary. Thanks for the quick help though!
