And I don't understand why. I'm suspecting it is a namespace issue but the function and its calls are defined within the same doc ready function.
When I try to call the function in the console I get calcPCs is not defined
$(document).ready(function() {
function calcPCs(id) {
var si = $(id).find(".Screened-In").text();
var so = $(id).find(".Screened-Out").text();
var ref = $(id).find(".Referred").text();
var ret = $(id).find(".Retained").text();
$(id).find(".Screened-In").append(' (' + Math.floor((+si / (+si + +so)) * 100) + '%)');
$(id).find(".Screened-Out").append(' (' + Math.floor((+so / (+si + +so)) * 100) + '%)');
$(id).find(".Referred").append(' (' + Math.floor((+ref / (+ref + +ret)) * 100) + '%)');
$(id).find(".Retained").append(' (' + Math.floor((+ret / (+ref + +ret)) * 100) + '%)');
};
calcPCs("#northwest");
calcPCs("#northeast");
calcPCs("#west");
calcPCs("#east");
calcPCs("#central");
calcPCs("#gtr");
});