ureech,
<script>
function fn(arr)
{ let keys = Object.keys(arr[0]), obj = {};
keys.forEach(k => obj[k] = []);
arr.forEach(a => keys.forEach(k => obj[k].push(+a[k])));
return keys.map(k => ({name : k, data : obj[k]}))
}
let res = [{ to_fact_hip: "10.00", to_fact_neck: "30.00", to_fact_weist: "20.00"},
{ to_fact_hip: "10.00", to_fact_neck: "30.00", to_fact_weist: "20.00"},
{ to_fact_hip: "0.00", to_fact_neck: "0.00", to_fact_weist: "0.00"}]
let totall = fn(res)
document.write(JSON.stringify(totall, "", 4))
</script>