Nitrate Levels in Well Locations
Throughout Wisconsin
and Cancer Rates

Turf.js interpolate is used to perform the inverse distance weighted interpolation on the nitrate data from the Well Points. Turf.jscollect is used to join the cancer rate data and the IDW values. This result is displayed as an average IDW value on the map. Regression.js and Statistics.js are then passed this result to create a linear regression model and correlation coefficient. Chart.js is then passed that model and displays a scatter plot and regression line.

Scatter Plot and Regression Line

Regression Equation

y = mx + c

Where m = gradient and c = yIntercept

Pearson’s Correlation Coefficient

Where value of -1 is negative correlation
and value of 1 is positive correlation