缺失值區域圖



以下是缺失值區域圖示例

我們在 Google Charts 配置語法 章節中已瞭解了繪製圖表時使用的配置。現在,讓我們來看一個缺失值區域圖示例。

示例

app.component.ts

import { Component } from '@angular/core';
@Component({
   selector: 'app-root',
   templateUrl: './app.component.html',
   styleUrls: ['./app.component.css']
})
export class AppComponent {
   title = 'Area Chart';
   type = 'AreaChart';
   data = [
      ["2013", 1000, 400],
      ["2014", 1170, 460],
      ["2015", null, 1120],
      ["2016", 1030, 540]
   ];
   columnNames = ['Year', 'Sales',"Expenses"];
   options = { };
   width = 550;
   height = 400;
}

結果

驗證結果。

Area Chart with missing values
angular_googlecharts_area_charts.htm
廣告
© . All rights reserved.