anychart.onDocumentReady(function () {
var stage = anychart.graphics.create('container');
var chart = anychart.pyramid([
{x: 'Physical', value: 125},
{x: 'Data Link', value: 125},
{x: 'Network', value: 125},
{x: 'Transport', value: 125},
{x: 'Session', value: 125},
{x: 'Presentation', value: 125},
{x: 'Application', value: 290}
chart.title('Serialize chart object to JSON');
chart.bounds(0, 0, '50%', '100%');
var json = chart.toJson();
var chartFromJson = anychart.fromJson(json);
chartFromJson.bounds('50%', 0, '50%', '100%');
chartFromJson.title('Creates chart from JSON object');
chartFromJson.container(stage);