diff --git chart.module chart.module
index 55d1601..3c3af64 100644
--- chart.module
+++ chart.module
@@ -629,6 +629,7 @@ function _chart_append($attr, $value, &$data) {
       if (count($regular)) {
         foreach ($regular as $axis => $indices) {
           if (count($indices)) {
+            $data['chxl'] = '';              
             foreach ($indices as $i => $labels) {
               $types[] = $axis;
               $data['chxl'] .= $index . ':';
@@ -649,8 +650,9 @@ function _chart_append($attr, $value, &$data) {
       }
       // Generate positions
       if (count($positions)) {
+        $data['chxp'] = '';
         foreach ($positions as $i => $position) {
-          if ($position['set'] == TRUE) {
+          if (isset($position['set']) && $position['set'] == TRUE) {
             $data['chxp'] .= $i . ',' . implode(',', $position['data']) .  '|';
           }
         }
