2015-03-25 62 views
0

一系列具体我现在有一个煎茶线图看起来像这样:缩放与煎茶图表

xtype: 'chart', 
        height: '100%', 
        store: 'ExperimentDataStore', 
        axes: [ 
         { 
          type: 'numeric', 
          fields: [ 
           'pmc1Value' 
          ], 
          grid: true, 
          minimum: 0, 
          position: 'left', 
          title: 'PMC1Value' 
         }, 
         { 
          type: 'numeric', 
          fields: [ 
           'temperature' 
          ], 
          position: 'left', 
          title: 'test' 
         }, 
         { 
          type: 'numeric', 
          fields: [ 
           'temperature' 
          ], 
          position: 'left', 
          title: 'pmc6Value' 
         }, 
         { 
          type: 'category', 
          fields: [ 
           'timestamp' 
          ], 
          title: 'Name' 
         } 
        ], 
        series: [ 
         { 
          type: 'line', 
          colors: [ 
           'rgba(0,0,0,0.1)' 
          ], 
          style: { 
           smooth: false, 
           stroke: '#000' 
          }, 
          xField: 'timestamp', 
          yField: 'temperature' 
         }, 
         { 
          type: 'line', 
          colors: 'rgba(0,200,0,0.3)', 
          style: { 
           smooth: true, 
           stroke: 'rgb(0,200,0)', 

          }, 
          xField: 'timestamp', 
          yField: 'pmc1Value' 
         } 
        ], 
        interactions: [ 
         { 
          type: 'panzoom', 
          zoomOnPanGesture: true, 
          axes: { 
           top: false, 
           right: false, 
           bottom: false, 
           left: true 
          } 
         } 
        ] 
       } 

目前的变焦操作放大Y轴左侧为我所有的图表系列。但我想要的只是放大一个特定的系列,而不是全部。这可以做到吗?

回答

0

不,您不能在单个系列上使用PanZoom。 PanZoom交互只能在Axis级别而不是系列级别配置。不支持缩放单个系列。

但是,假设它可以完成,你可以通过放大特定系列来描述你想要的行为吗?就像你想如何想象其他系列一样?你会有失真的尺度。