Open olmozavala opened 2 years ago
Adding this in drawParticlesAsLines()
:
if(disp_part && (Math.abs(clon-nlon)<180)){
}
and for the case without NaN
if (Math.abs(clon-nlon)<180){
fixes the problem.
If we do this in the preprocessing, it might be a bit cleaner, probably faster, but then we will need the extra data_int
because we are adding NaN
to the longitude and latitude. What do you think?
When PV displays lines of locations that are crossing from 180 to -180 or vice-versa, a line crossing the map appears. After brainstorming we consider the best opinion is not to display that single line. One way to do it is during the preprocessing step at /https://github.com/olmozavala/particleviz/blob/master/ParticleViz_DataPreproc/PreprocParticleViz.py#71 identify the particles that will have this behaviour and include them in the bit_dispaly_array.