Skip to content
Advertisement

Amcharts – How to remove gridlines but keep the base x and y axis

How can I remove only the gridlines and keep the x-axis and y-axis base line in Amcharts4. I’m using Amcharts with Vuejs. Here the code of the chart component

JavaScript

Both axis and gridlines are removed using when :

JavaScript

This is the output graph of the above code. I need to show both x and y base axis and only the gridlines removed.

Advertisement

Answer

You can set the axis renderer’s line object strokeOpacity to a non-zero value to show the axis lines:

JavaScript

Demo:

JavaScript
JavaScript
User contributions licensed under: CC BY-SA
4 People found this is helpful
Advertisement