Angular Google Charts Tutorial
Angular Google Charts Resources
Selected Reading
- TreeMap Chart
- Table Chart
- Stepped Area
- Scatter Chart
- Sankey Charts
- Pie Charts
- Organization
- Maps
- Line Charts
- Histogram
- Combination
- Column Charts
- Candlestick
- Bubble Charts
- Bar Charts
- Area Charts
- Configuration Syntax
- Environment Setup
- Overview
- Home
Angular Google Charts Resources
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Table Chart
Angular Google Charts - Table Charts
Table chart helps in rendering a table which can be sorted and paged. Table cells can be formatted using format strings, or by directly inserting HTML as cell values. Numeric values are right-apgned by default; boolean values are displayed as check marks or cross marks. Users can select single rows either with the keyboard or the mouse. Column headers can be used for sorting. The header row remains fixed during scrolpng. The table fires events corresponding to user interaction.
We have already seen the configurations used to draw a chart in
chapter. Now, let us see an example of a Table Chart.Configurations
We ve used Table class to show a Table chart.
type = Table ;
Example
app.component.ts
import { Component } from @angular/core ; @Component({ selector: app-root , templateUrl: ./app.component.html , styleUrls: [ ./app.component.css ] }) export class AppComponent { title = ""; type = Table ; data = [ [ Mike , {v: 10000, f: $10,000 }, true], [ Jim , {v:8000, f: $8,000 }, false], [ Apce , {v: 12500, f: $12,500 }, true], [ Bob , {v: 7000, f: $7,000 }, true] ]; columnNames = ["Name", "Salary","Full Time Employee"]; options = { alternatingRowStyle:true, showRowNumber:true }; width = 550; height = 400; }
Result
Verify the result.
Advertisements