I have a pretty big vtk file I’m importing into paraview with points organized in a mesh where every vertex contains info about a current density.
The current density goes from 0 to 4.9e9.
When I use the Threshold filter I set a lower limit to 2.547e9 (leaving the upper limit as is).
Upon applying the filter, if I plot the points on a spreadsheet, I can see that the points close to the upper limit of the threshold range just “disappear”!
I mean, if I open the spreadsheet without any threshold filter, I can definitely see the point I’m looking for and its coordinates. If I apply a threshold of 2.547e9, the point disappears. If I apply a lower limit of 2e9, the point reappears!
Is there anything wrong I’m doing or any unknown bug (threshold dealing just with integer numbers??)
Let me know
Can you share a dataset to reproduce the behavior with ?
I am going to guess that the problem you are encountering is that the
Threshold filter is applying its criteria to cells, not points. A point will pass the threshold if an only if it is attached to a cell that matches the criteria.
By default, a cell will be removed if any of the points it is attached to is outside the threshold range. It is reasonably likely that a point that is just above the lower limit is connected only to cells with at least one other incident point below the lower limit. Since all the incident cells are removed, that point gets removed, too. You can change the
All Scalars option to keep cells with any of the incident points matching the threshold range. But then you will have the opposite problem; you will pass several points below the lower limit.
If this is the issue, it is another form of the question asked here: Thresholding Nodal Information in VTK file. The solution is the same, too. Use the
Glyph filter to create a separate cell for each point.
As an alternative, if you don’t mind the cells being “cut up” you can use the
IsoVolume filter which behaves quite similar to the
Threshold filter except instead of keeping or throwing away the entire cell based on the threshold criteria it will cut up the cell instead based on the criteria and only keep the part of the cell that matches the criteria.
Thanks Andy: isoVolume does the job! I’ll have to integrate those points with the ones I obtain from the Threshold filter to get the full picture of the data I need, but that’s not an issue