V3: Line with custom bullets
HTML
<script src="http://www.amcharts.com/lib/3/amcharts.js"></script>
<script src="http://www.amcharts.com/lib/3/serial.js"></script>
<div id="chartdiv" style="width: 100%; height: 362px;"></div>
JavaScript
// since v3, chart can accept data in JSON format
// if your category axis parses dates, you should only
// set date format of your data (dataDateFormat property of AmSerialChart)
var lineChartData = [{
"date": "2009-10-02",
"value": 5
}, {
"date": "2009-10-03",
"value": 15
}, {
"date": "2009-10-04",
"value": 13
}, {
"date": "2009-10-05",
"value": 17
}, {
"date": "2009-10-06",
"value": 15
}, {
"date": "2009-10-09",
"value": 19
}, {
"date": "2009-10-10",
"value": 21
}, {
"date": "2009-10-11",
"value": 20
}, {
"date": "2009-10-12",
"value": 20
}, {
"date": "2009-10-13",
"value": 19
}, {
"date": "2009-10-16",
"value": 25
}, {
"date": "2009-10-17",
"value": 24
}, {
"date": "2009-10-18",
"value": 26
}, {
"date": "2009-10-19",
"value": 27
}, {
"date": "2009-10-20",
"value": 25
}, {
"date": "2009-10-23",
"value": 29
}, {
"date": "2009-10-24",
"value": 28
}, {
"date": "2009-10-25",
"value": 30
}, {
"date": "2009-10-26",
"value": 72,
"customBullet": "http://www.amcharts.com/lib/3/images/redstar.png"
}, {
"date": "2009-10-27",
"value": 43
}, {
"date": "2009-10-30",
"value": 31
}, {
"date": "2009-11-01",
"value": 30
}, {
"date": "2009-11-02",
"value": 29
}, {
"date": "2009-11-03",
"value": 27
}, {
"date": "2009-11-04",
"value": 26
}];
AmCharts.ready(function () {
var chart = new AmCharts.AmSerialChart();
chart.dataProvider = lineChartData;
chart.pathToImages = "http://www.amcharts.com/lib/3/images/";
chart.categoryField = "date";
chart.dataDateFormat = "YYYY-MM-DD";
// sometimes we need to set margins manually
// autoMargins should be set to false in order chart to use custom margin values
chart.autoMargins = false;
...