diff options
Diffstat (limited to 'calc_error.m')
-rw-r--r-- | calc_error.m | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/calc_error.m b/calc_error.m new file mode 100644 index 0000000..1f525ba --- /dev/null +++ b/calc_error.m @@ -0,0 +1,13 @@ +function calc_error(data, pred) + + quad = quad_error(data, pred); + total = total_error(data, pred); + + printf('quad mean : %9d\n', quad); + printf('total mean : %9d\n', total); + + plot((sum(abs(data - pred))), 'b'); + hold on; + plot(sort(sum(abs(data - pred))), 'r'); + hold off; +end |