The existing implementation is finicky and now relies on outdated internal dependencies.
Just noting here that @StefanoGitHub has a pull request open on this in the old turf-isobands repo.
@DenisCarriere do I understand correctly that the isolines module has currently issues/bug as well? Don't get exactly which ones though.
Would you like me to take a look into this and maybe trying to replace conrec with marchingsquare.isolines?
@DenisCarriere Looking at the module's test it seems to me that the output is incorrect... am I wrong?
Other consideration: what's actually the difference between an isoline and an isoband?
The more I think about this it seems to me the isoline is just a particular case of isoband, where its two limits (upper and lower) coincide.
Couldn't we just use the same algorithm for both isobands and isolines? It would be probably mainly a matter of output format, MultiPolygons vs. LinearRing or LineString.
In this example for instance it's also clear that the conrec algorithm/library does not "group" isolines of the same level, considering each line indipendent. I don't think this is a desired result for whom needs isolines.
Well ideally we should only have 1 module, the only difference is the Polygon & LineString outputs.
Once we get isobands up and running we could drop isolines (turf 4.x) in favor of isobands.
Well ideally we should only have 1 module, the only difference is the Polygon & LineString outputs.
Note that we used to have isobands and isolines, but isobands was deprecated due to limitations in the conrec implementation that did not apply to LineString output. Having both might be useful, and turning one format into the other can be surprisingly tricky for people looking for a quick result.