After providing detailed information about my issue, I was criticized for seeking help, so I will be more general in my explanation. I am trying to calculate the sum of values for each location within a polygon drawn on Mapbox. I have the code to insert the draw polygon tool, draw the polygon, and display the summed values on the left side of the map. However, the calculated value is incorrect and I am unsure why. I am feeling frustrated and at a loss. Can anyone offer insight into this issue?
While browsing other posts on stackoverflow, I have gathered that seeking help is acceptable when encountering problems. I am open to receiving advice and guidance on how to fix my code. I am not asking to be spoonfed; I genuinely want to comprehend the issues with my code and learn from them. If you require access to my code, please let me know.