{"id":5857,"date":"2018-05-02T08:37:38","date_gmt":"2018-05-02T08:37:38","guid":{"rendered":"https:\/\/www.anychart.com\/blog\/?p=5857"},"modified":"2018-12-27T05:51:52","modified_gmt":"2018-12-27T05:51:52","slug":"half-polar-chart-javascript-challenge-anychart","status":"publish","type":"post","link":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/","title":{"rendered":"Creating Half Polar Chart with JavaScript \u2014 Challenge AnyChart!"},"content":{"rendered":"<p><img decoding=\"async\" class=\"alignnone size-full wp-image-5975\" src=\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png\" alt=\"Half Polar Chart \u2014 Challenge AnyChart!\" width=\"100%\" srcset=\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png 960w, https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar-300x200.png 300w, https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar-768x512.png 768w\" sizes=\"(max-width: 960px) 100vw, 960px\" \/><br \/>\nChallenges are always fun, and we at AnyChart adore taking them up from our customers. <a href=\"https:\/\/www.anychart.com\/support\/\">AnyChart Support Team<\/a> is happy to show how flexible <a href=\"https:\/\/www.anychart.com\/\">AnyChart JS Charts<\/a> are. Today\u2019s <a>Challenge AnyChart<\/a> tutorial is about <a href=\"https:\/\/www.anychart.com\/chartopedia\/chart-type\/polar-chart\/\">JS polar charts<\/a>. Spend about 5 minutes and you\u2019ll find out how to draw a beautiful polar chart, but display only its one half, making it a half polar chart.<\/p>\n<p><!--more--><\/p>\n<h2>Data Visualization Task<\/h2>\n<p>The question a customer wanted us to answer:<\/p>\n<blockquote><p><em><strong>Is it possible to show just a half of a Polar Chart in AnyChart JS Charts?<br \/>\n<\/strong><\/em><\/p><\/blockquote>\n<p>To explain what he is willing to see on his chart, the customer sent us a link to the following picture:<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/04\/half_polar_sample.png\" alt=\"Half Polar Chart with polylines and dotted grids\" width=\"70%\" height=\"70%\" \/><\/p>\n<p>To solve this task, we need some knowledge of the <a href=\"https:\/\/api.anychart.com\/anychart.charts.Polar\" target=\"_blank\" rel=\"nofollow\">API methods of Polar chart class<\/a> to move a polar chart to the left and draw colored lines on it.<\/p>\n<h2>Solution Overview<\/h2>\n<p>To begin with, we set a container and draw a <a href=\"https:\/\/docs.anychart.com\/Basic_Charts\/Polar_Plot\/Overview\" target=\"_blank\" rel=\"nofollow\">polar chart<\/a> inside it. Next, we simply move a half of the chart beyond the container boundaries and change the chart appearance.<\/p>\n<h2>Displaying Half Polar Chart<\/h2>\n<p>To deal with the main task, we create a function where we use the <a href=\"https:\/\/api.anychart.com\/anychart.charts.Polar#left\" target=\"_blank\" rel=\"nofollow\">chart.left()<\/a> method. In this case, the chart is moved to the left by the width of the container (to hide a half of the chart) plus 30 (to make the axis labels look better).<\/p>\n<pre><code class=\"javascript\">function relocateChart(chart) {\r\n  chart.left(-chart.container().getBounds().width+30);\r\n}\r\n<\/code><\/pre>\n<p>The function is executed before we initiate chart drawing and every time when the container is resized, so our chart stays in place.<\/p>\n<pre><code class=\"javascript\">chart.listen('chartDraw', function(){\r\n  relocateChart(chart);\r\n});\r\n<\/code><\/pre>\n<p>That\u2019s it! The <a href=\"https:\/\/playground.anychart.com\/esGjs0T5\" target=\"_blank\" rel=\"nofollow\">Half Polar Chart<\/a> is ready to be presented!<\/p>\n<p><iframe loading=\"lazy\" class=\"anychart-embed anychart-embed-esGjs0T5\" src=\"https:\/\/playground.anychart.com\/esGjs0T5\/iframe\" width=\"300\" height=\"150\" frameborder=\"0\" sandbox=\"allow-scripts allow-pointer-lock allow-same-origin allow-popups allow-modals allow-forms\" allowfullscreen=\"allowfullscreen\"><br \/>\n<\/iframe><br \/>\n<script type=\"text\/javascript\">(function(){\nfunction ac_add_to_head(el){\n\tvar head = document.getElementsByTagName('head')[0];\n\thead.insertBefore(el,head.firstChild);\n}\nfunction ac_add_style(css){\n\tvar ac_style = document.createElement('style');\n\tif (ac_style.styleSheet) ac_style.styleSheet.cssText = css;\n\telse ac_style.appendChild(document.createTextNode(css));\n\tac_add_to_head(ac_style);\n}\nac_add_style(\".anychart-embed-esGjs0T5{width:100%;height:600px;}\");\n})();<\/script><\/p>\n<p>As you see, some challenges are actually easy tasks when there is a proper method in the API. Now let\u2019s go through the <a href=\"https:\/\/api.anychart.com\/anychart.charts.Polar\" target=\"_blank\" rel=\"nofollow\">Polar Chart<\/a> section of the API to set up the chart appearance.<\/p>\n<h2>Changing Chart Appearance<\/h2>\n<p>What we should do here is draw several colored lines on the chart, display labels in the given format, and make the grid lines dotted.<\/p>\n<p>First of all, we add some data to the data sets:<\/p>\n<pre><code class=\"javascript\">var data = [\r\n    {x: 52, value: 5.5},\r\n    {x: 60, value: 5.9},\r\n    {x: 75, value: 6.24},\r\n    {x: 90, value: 6.24},\r\n    {x: 110, value: 6.28},\r\n    {x: 120, value: 6.08},\r\n    {x: 135, value: 5.36},\r\n    {x: 150, value: 4.5},\r\n    {x: 160, value: null},\r\n];\r\n<\/code><\/pre>\n<p>Now we display <a href=\"https:\/\/docs.anychart.com\/Basic_Charts\/Polyline_Chart\" target=\"_blank\" rel=\"nofollow\">lines<\/a> using the data and setting specific color for each series:<\/p>\n<pre><code class=\"javascript\">var series = chart.polyline(data);\r\nseries.color(\"#4d9ece\");\r\n<\/code><\/pre>\n<p>Then we display labels as we see fit:<\/p>\n<pre><code class=\"javascript\">chart.yAxis().labels().anchor('left-center')\r\n    .offsetY(-2)\r\n    .format('{%value}kts')\r\n<\/code><\/pre>\n<p>And customize the grid making the grid lines dotted:<\/p>\n<pre><code class=\"javascript\">chart.xGrid().stroke({\r\n    dash: \"1 5\"\r\n});\r\n<\/code><\/pre>\n<p>There it is! Now the chart looks like the one in the picture. You can try and modify this <a href=\"https:\/\/playground.anychart.com\/9DKHYgU3\" target=\"_blank\" rel=\"nofollow\">half polar chart sample at AnyChart Playground<\/a>:<\/p>\n<p><iframe loading=\"lazy\" class=\"anychart-embed anychart-embed-9DKHYgU3\" src=\"https:\/\/playground.anychart.com\/9DKHYgU3\/iframe\" width=\"300\" height=\"150\" frameborder=\"0\" sandbox=\"allow-scripts allow-pointer-lock allow-same-origin allow-popups allow-modals allow-forms\" allowfullscreen=\"allowfullscreen\"><br \/>\n<\/iframe><br \/>\n<script type=\"text\/javascript\">(function(){\nfunction ac_add_to_head(el){\n\tvar head = document.getElementsByTagName('head')[0];\n\thead.insertBefore(el,head.firstChild);\n}\nfunction ac_add_style(css){\n\tvar ac_style = document.createElement('style');\n\tif (ac_style.styleSheet) ac_style.styleSheet.cssText = css;\n\telse ac_style.appendChild(document.createTextNode(css));\n\tac_add_to_head(ac_style);\n}\nac_add_style(\".anychart-embed-9DKHYgU3{width:100%;height:600px;}\");\n})();<\/script><\/p>\n<p>For more information look at the full code below:<\/p>\n<pre><code class=\"javascript\">anychart.onDocumentReady(function () {\r\n\r\nvar chart = anychart.polar();\r\n\r\n\/\/ add the lines to the chart\r\nvar series = chart.polyline(getData()[0]);\r\nseries.color(\"#4d9ece\");\r\nvar series2 = chart.polyline(getData()[1]);\r\n  series2.color(\"#ff9941\");\r\n  var series3 = chart.polyline(getData()[2]);\r\n  series3.color(\"#0db341\");\r\n  var series4 = chart.polyline(getData()[3]);\r\n  series4.color(\"#f35556\");\r\n  var series5 = chart.polyline(getData()[4]);\r\n  series5.color(\"#ad6ac7\");\r\n  var series6 = chart.polyline(getData()[5]);\r\n  series6.color(\"#16ccda\");\r\n  var series7 = chart.polyline(getData()[6]);\r\n  series7.color(\"#f873c7\");\r\n\r\n  \/\/ set the maximum value of the x-scale\r\n  chart.xScale().maximum(360)\r\n    .ticks([0,45,52,60,75,90,110,120,135,150,165]);\r\n  chart.yScale().minimum(0)\r\n    .ticks([0,2,4,6,8,10]);\r\n  chart.yScale().maximum(10);\r\n\r\n  \/\/ format labels\r\n  chart.yAxis().labels().anchor('left-center')\r\n    .offsetY(-2)\r\n    .format('{%value}kts')\r\n  chart.xAxis().labels().format('{%value}\u00b0')\r\n  chart.xAxis().ticks().length(0);\r\n\r\n  \/\/ customize grids\r\n  chart.xGrid().stroke({\r\n    dash: \"1 5\"\r\n  });\r\n  chart.yGrid().stroke({\r\n    dash: \"1 5\"\r\n  });\r\n\r\n  \/\/ set the container id\r\n  chart.container(\"container\");\r\n  relocateChart(chart);\r\n  chart.draw();\r\n\r\n  chart.listen('chartDraw', function(){\r\n    relocateChart(chart);\r\n  });\r\n});\r\n\r\nfunction relocateChart(chart) {\r\n  chart.left(-chart.container().getBounds().width+30);\r\n}\r\n\r\nfunction getData() {\r\n  return [[\r\n    {x: 52, value: 5.5},\r\n    {x: 60, value: 5.9},\r\n    {x: 75, value: 6.24},\r\n    {x: 90, value: 6.24},\r\n    {x: 110, value: 6.28},\r\n    {x: 120, value: 6.08},\r\n    {x: 135, value: 5.36},\r\n    {x: 150, value: 4.5},\r\n    {x: 160, value: null},\r\n  ],\r\n          [\r\n            {x: 52, value: 6.6},\r\n            {x: 60, value: 6.85},\r\n            {x: 75, value: 7.02},\r\n            {x: 90, value: 7.06},\r\n            {x: 110, value: 7.21},\r\n            {x: 120, value: 7.1},\r\n            {x: 135, value: 6.65},\r\n            {x: 150, value: 5.66},\r\n            {x: 160, value: null},\r\n          ],\r\n          [\r\n            {x: 52, value: 6.98},\r\n            {x: 60, value: 7.19},\r\n            {x: 75, value: 7.42},\r\n            {x: 90, value: 7.47},\r\n            {x: 110, value: 7.71},\r\n            {x: 120, value: 7.71},\r\n            {x: 135, value: 7.31},\r\n            {x: 150, value: 6.65},\r\n            {x: 160, value: null},\r\n          ],   \r\n          [\r\n            {x: 52, value: 7.12},\r\n            {x: 60, value: 7.34},\r\n            {x: 75, value: 7.74},\r\n            {x: 90, value: 7.95},\r\n            {x: 110, value: 8.08},\r\n            {x: 120, value: 8.36},\r\n            {x: 135, value: 7.91},\r\n            {x: 150, value: 7.25},\r\n            {x: 160, value: null},\r\n          ],\r\n          [\r\n            {x: 52, value: 7.2},\r\n            {x: 60, value: 7.44},\r\n            {x: 75, value: 7.94},\r\n            {x: 90, value: 8.42},\r\n            {x: 110, value: 8.48},\r\n            {x: 120, value: 8.82},\r\n            {x: 135, value: 8.7},\r\n            {x: 170, value: 7},\r\n            {x: 175, value: null},\r\n          ],\r\n          [\r\n            {x: 52, value: 7.3},\r\n            {x: 60, value: 7.53},\r\n            {x: 75, value: 8.07},\r\n            {x: 90, value: 8.72},\r\n            {x: 110, value: 8.87},\r\n            {x: 120, value: 9.27},\r\n            {x: 135, value: 9.71},\r\n            {x: 150, value: 8.34},\r\n            {x: 160, value: null},\r\n          ],\r\n          [\r\n            {x: 52, value: 7.41},\r\n            {x: 60, value: 7.73},\r\n            {x: 75, value: 8.35},\r\n            {x: 90, value: 8.99},\r\n            {x: 110, value: 9.89},\r\n            {x: 120, value: 10.22},\r\n            {x: 135, value: 11.4},\r\n            {x: 150, value: 10.43},\r\n            {x: 160, value: null},\r\n          ]];\r\n}\r\n<\/code><\/pre>\n<hr \/>\n<p><a href=\"https:\/\/www.anychart.com\/support\/\">AnyChart Support Team<\/a> is waiting for your original tasks. If you have one, please send it via email at <a href=\"mailto:support@anychart.com\" target=\"_blank\" rel=\"nofollow\">support@anychart.com<\/a> with \u201cChallenge\u201d in the subject line. You\u2019ll see that <a href=\"https:\/\/www.anychart.com\/\">AnyChart JS Charts<\/a> are capable of everything.<\/p>\n<p>We are glad if this article about how to build a half polar chart with JavaScript was useful to you! Feel free to share your questions and thoughts about <a href=\"https:\/\/www.anychart.com\/blog\/category\/challenge-anychart\/\">Challenge AnyChart!<\/a>. And maybe, your\u00a0task will become the topic of our next post!<\/p>\n<p><!-- SyntaxHighlighter --><link rel=\"stylesheet\" href=\"\/\/cdnjs.cloudflare.com\/ajax\/libs\/highlight.js\/9.12.0\/styles\/default.min.css\"><link rel=\"stylesheet\" href=\"\/\/cdnjs.cloudflare.com\/ajax\/libs\/highlight.js\/9.12.0\/styles\/atom-one-light.min.css\"><script src=\"\/\/cdnjs.cloudflare.com\/ajax\/libs\/highlight.js\/9.12.0\/highlight.min.js\"><\/script><script>hljs.initHighlightingOnLoad();<\/script><\/p>\n<!-- AddThis Advanced Settings generic via filter on the_content --><!-- AddThis Share Buttons generic via filter on the_content -->","protected":false},"excerpt":{"rendered":"<p>Challenges are always fun, and we at AnyChart adore taking them up from our customers. AnyChart Support Team is happy to show how flexible AnyChart JS Charts are. Today\u2019s Challenge AnyChart tutorial is about JS polar charts. Spend about 5 minutes and you\u2019ll find out how to draw a beautiful polar chart, but display only [&hellip;]<!-- AddThis Advanced Settings generic via filter on get_the_excerpt --><!-- AddThis Share Buttons generic via filter on get_the_excerpt --><\/p>\n","protected":false},"author":13,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,280,22,23,13,4],"tags":[53,281,258,44,54,32,55,36,141,81,57,58,65,56,207,30,172],"class_list":["post-5857","post","type-post","status-publish","format-standard","hentry","category-anychart-charting-component","category-challenge-anychart","category-charts-and-art","category-html5","category-javascript","category-tips-and-tricks","tag-anychart","tag-challenge","tag-charts","tag-charts-and-art","tag-data-visualization","tag-html5","tag-html5-charts","tag-javascript","tag-javascript-charting","tag-javascript-charting-library","tag-javascript-charts","tag-js-chart","tag-js-charting","tag-js-charts","tag-polar-chart","tag-tips-and-tricks","tag-tutorial","wpautop"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Half Polar Chart with JavaScript \u2014 Challenge AnyChart!<\/title>\n<meta name=\"description\" content=\"Today\u2019s &#039;Challenge AnyChart!&#039; tutorial is about how to draw a beautiful JavaScript polar chart, but display only its one half, making it a half polar chart.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Half Polar Chart with JavaScript \u2014 Challenge AnyChart!\" \/>\n<meta property=\"og:description\" content=\"Today\u2019s &#039;Challenge AnyChart!&#039; tutorial is about how to draw a beautiful JavaScript polar chart, but display only its one half, making it a half polar chart.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/\" \/>\n<meta property=\"og:site_name\" content=\"AnyChart News\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/AnyCharts\" \/>\n<meta property=\"article:published_time\" content=\"2018-05-02T08:37:38+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2018-12-27T05:51:52+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png\" \/>\n\t<meta property=\"og:image:width\" content=\"960\" \/>\n\t<meta property=\"og:image:height\" content=\"640\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Irina Maximova\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@AnyChart\" \/>\n<meta name=\"twitter:site\" content=\"@AnyChart\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Irina Maximova\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/\"},\"author\":{\"name\":\"Irina Maximova\",\"@id\":\"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/c79061b5c43d09368b8d44b36842b058\"},\"headline\":\"Creating Half Polar Chart with JavaScript \u2014 Challenge AnyChart!\",\"datePublished\":\"2018-05-02T08:37:38+00:00\",\"dateModified\":\"2018-12-27T05:51:52+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/\"},\"wordCount\":495,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png\",\"keywords\":[\"AnyChart\",\"challenge\",\"charts\",\"Charts and Art\",\"Data Visualization\",\"HTML5\",\"html5 charts\",\"JavaScript\",\"javascript charting\",\"JavaScript charting library\",\"javascript charts\",\"js chart\",\"js charting\",\"js charts\",\"polar chart\",\"Tips and tricks\",\"tutorial\"],\"articleSection\":[\"AnyChart Charting Component\",\"Challenge AnyChart!\",\"Charts and Art\",\"HTML5\",\"JavaScript\",\"Tips and Tricks\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/\",\"url\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/\",\"name\":\"Half Polar Chart with JavaScript \u2014 Challenge AnyChart!\",\"isPartOf\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png\",\"datePublished\":\"2018-05-02T08:37:38+00:00\",\"dateModified\":\"2018-12-27T05:51:52+00:00\",\"author\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/c79061b5c43d09368b8d44b36842b058\"},\"description\":\"Today\u2019s 'Challenge AnyChart!' tutorial is about how to draw a beautiful JavaScript polar chart, but display only its one half, making it a half polar chart.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage\",\"url\":\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png\",\"contentUrl\":\"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png\",\"width\":960,\"height\":640},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.anychart.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Creating Half Polar Chart with JavaScript \u2014 Challenge AnyChart!\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.anychart.com\/blog\/#website\",\"url\":\"https:\/\/www.anychart.com\/blog\/\",\"name\":\"AnyChart News\",\"description\":\"AnyChart JS Charts\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.anychart.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/c79061b5c43d09368b8d44b36842b058\",\"name\":\"Irina Maximova\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/023075cf0bac635343d009a289d4c3d32138b5a3890d10f09ed59755e59bc065?s=96&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/023075cf0bac635343d009a289d4c3d32138b5a3890d10f09ed59755e59bc065?s=96&r=g\",\"caption\":\"Irina Maximova\"},\"url\":\"https:\/\/www.anychart.com\/blog\/author\/irina-maximova\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Half Polar Chart with JavaScript \u2014 Challenge AnyChart!","description":"Today\u2019s 'Challenge AnyChart!' tutorial is about how to draw a beautiful JavaScript polar chart, but display only its one half, making it a half polar chart.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/","og_locale":"en_US","og_type":"article","og_title":"Half Polar Chart with JavaScript \u2014 Challenge AnyChart!","og_description":"Today\u2019s 'Challenge AnyChart!' tutorial is about how to draw a beautiful JavaScript polar chart, but display only its one half, making it a half polar chart.","og_url":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/","og_site_name":"AnyChart News","article_publisher":"https:\/\/www.facebook.com\/AnyCharts","article_published_time":"2018-05-02T08:37:38+00:00","article_modified_time":"2018-12-27T05:51:52+00:00","og_image":[{"width":960,"height":640,"url":"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png","type":"image\/png"}],"author":"Irina Maximova","twitter_card":"summary_large_image","twitter_creator":"@AnyChart","twitter_site":"@AnyChart","twitter_misc":{"Written by":"Irina Maximova","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#article","isPartOf":{"@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/"},"author":{"name":"Irina Maximova","@id":"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/c79061b5c43d09368b8d44b36842b058"},"headline":"Creating Half Polar Chart with JavaScript \u2014 Challenge AnyChart!","datePublished":"2018-05-02T08:37:38+00:00","dateModified":"2018-12-27T05:51:52+00:00","mainEntityOfPage":{"@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/"},"wordCount":495,"commentCount":0,"image":{"@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage"},"thumbnailUrl":"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png","keywords":["AnyChart","challenge","charts","Charts and Art","Data Visualization","HTML5","html5 charts","JavaScript","javascript charting","JavaScript charting library","javascript charts","js chart","js charting","js charts","polar chart","Tips and tricks","tutorial"],"articleSection":["AnyChart Charting Component","Challenge AnyChart!","Charts and Art","HTML5","JavaScript","Tips and Tricks"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/","url":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/","name":"Half Polar Chart with JavaScript \u2014 Challenge AnyChart!","isPartOf":{"@id":"https:\/\/www.anychart.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage"},"image":{"@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage"},"thumbnailUrl":"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png","datePublished":"2018-05-02T08:37:38+00:00","dateModified":"2018-12-27T05:51:52+00:00","author":{"@id":"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/c79061b5c43d09368b8d44b36842b058"},"description":"Today\u2019s 'Challenge AnyChart!' tutorial is about how to draw a beautiful JavaScript polar chart, but display only its one half, making it a half polar chart.","breadcrumb":{"@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#primaryimage","url":"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png","contentUrl":"https:\/\/www.anychart.com\/blog\/wp-content\/uploads\/2018\/05\/half_polar.png","width":960,"height":640},{"@type":"BreadcrumbList","@id":"https:\/\/www.anychart.com\/blog\/2018\/05\/02\/half-polar-chart-javascript-challenge-anychart\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.anychart.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Creating Half Polar Chart with JavaScript \u2014 Challenge AnyChart!"}]},{"@type":"WebSite","@id":"https:\/\/www.anychart.com\/blog\/#website","url":"https:\/\/www.anychart.com\/blog\/","name":"AnyChart News","description":"AnyChart JS Charts","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.anychart.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/c79061b5c43d09368b8d44b36842b058","name":"Irina Maximova","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.anychart.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/023075cf0bac635343d009a289d4c3d32138b5a3890d10f09ed59755e59bc065?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/023075cf0bac635343d009a289d4c3d32138b5a3890d10f09ed59755e59bc065?s=96&r=g","caption":"Irina Maximova"},"url":"https:\/\/www.anychart.com\/blog\/author\/irina-maximova\/"}]}},"_links":{"self":[{"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/posts\/5857","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/users\/13"}],"replies":[{"embeddable":true,"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/comments?post=5857"}],"version-history":[{"count":23,"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/posts\/5857\/revisions"}],"predecessor-version":[{"id":7154,"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/posts\/5857\/revisions\/7154"}],"wp:attachment":[{"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/media?parent=5857"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/categories?post=5857"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.anychart.com\/blog\/wp-json\/wp\/v2\/tags?post=5857"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}