RJ Quickcharts
[resolved] Remove or hide data labels / categories on x axis (4 posts)

  1. energynerd
    Posted 1 year ago #

    Hi ,

    First off, great plugin, really excellent work.

    I want to be able to produce a line graph to plot a year’s worth of data with daily granularity. If I put all of the dates in as labels, the x axis becomes illegible. I have tried to miss out some date labels to effectively try and just plot the month start date on the x-axis and have 12 labels but anything without a date label plots at the beginning of the x axis.

    Is there a way to plot a year’s worth of daily data but with a legible x axis?



  2. randyjensen
    Plugin Author

    Posted 1 year ago #

    Hey energynerd,

    The ability to disable axis labels is on my list of things to do. If you want to just modify the plugin, you can open shortcode/init.php and go to line 207.

    It should say "show: true,". Just change "true" to "false" (no tick marks).

    If that doesn't work, let me know and I'll find another solution.

  3. energynerd
    Posted 1 year ago #

    Thanks for coming back to me. I went to the shortcode/init.php and changed true to false in this section of the code:

    axes: {
    xaxis: $xAxis,
    renderer: jQuery.jqplot.LogAxisRenderer,
    tickRenderer: jQuery.jqplot.CanvasAxisTickRenderer,
    labelRenderer: jQuery.jqplot.CanvasAxisLabelRenderer,
    label: '$yAxisText',
    labelOptions: {
    show: false,
    fontSize: '14px'
    tickOptions: {
    mark: false,
    labelPosition: 'middle',
    angle: -90

    But the x-axis is still visible? Any other ideas? Ideally I would still like the x axis to be visible but just show a smaller number of labels.

  4. randyjensen
    Plugin Author

    Posted 1 year ago #

    OK, go ahead and undo that then.

    In that same file, look for line 74 which should look like this:

    $xAxis = "{
    label: '',

    Go ahead and add this line:

    numberTicks: 20,

    So it looks like this:

    $xAxis = "{
    numberTicks: 20,
    label: '',

    You can change "20" to anything you want. This should limit the number of ticks to something more reasonable.

    Let me know if that works for you.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • RJ Quickcharts
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic


No tags yet.