Difference between revisions of "Time series II"

From JSXGraph Wiki
Jump to navigationJump to search
Line 23: Line 23:
 
   ];
 
   ];
  
var googleStyleChart = function(board, x, y) {
+
var googleStyleChart = function(board, x, y, axisHeight) {
 
     var points = [], i, p;
 
     var points = [], i, p;
     points.push(brd2.createElement('point', [0,85], {visible:false, name:'', fixed:true, withLabel:false}));  
+
     points.push(board.createElement('point', [0, axisHeight], {visible:false, name:'', fixed:true, withLabel:false}));  
 
     for (i=0;i<x.length;i++) {  
 
     for (i=0;i<x.length;i++) {  
 
         p = board.create('point', [x[i],y[i]],  
 
         p = board.create('point', [x[i],y[i]],  
Line 33: Line 33:
 
         points.push(p);
 
         points.push(p);
 
     }
 
     }
     points.push(board.create('point', [x[x.length-1],2700], {visible:false, name:'', fixed:true}));  
+
     points.push(board.create('point', [x[x.length-1],axisHeight], {visible:false, name:'', fixed:true}));  
 
   
 
   
 
     // Filled area. We need two additional points [start,0] and [end,0]
 
     // Filled area. We need two additional points [start,0] and [end,0]
Line 52: Line 52:
 
     y[i] = table[i][1]*1;
 
     y[i] = table[i][1]*1;
 
}
 
}
googleStyleChart(brd,x,y);
+
googleStyleChart(brd,x,y,2700);
  
 
</jsxgraph>
 
</jsxgraph>

Revision as of 19:00, 3 February 2010

The weight of Antonia Wassermann