jQuery UI Widgets Forums Chart Polar Plot In Radians

This topic contains 1 reply, has 2 voices, and was last updated by  Hristo 7 years, 6 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • Polar Plot In Radians #93188

    jmentey
    Participant

    Hi,

    I’m trying to get polar plot for my data which has angles in radians vs pressure. My data is always in radians. So want to show the polar plot with labels showing from 0 to 2*pi. I converted the data to degrees and my intention was to just show the x axis labels in radians. I’m able to achieve that. But my tooltip shows the values in Pi.. I want them to show in radians. How do I achieve that?

    https://www.jseditor.io/?key=polar-plot-in-radians

    The tooltip showing values in PI.. The goal was to just rename labels..

    Also, my formatfunction in x-axis labels doesn’t seem to kick in. Its the other format function which takes the angles from the data that is working. Am I implementing it wrong?

    Regards,
    Jeswanth.

    Polar Plot In Radians #93194

    Hristo
    Participant

    Hello Jeswanth,

    You could try to add “toolTipFormatFunction” in the desired series.
    Please, take a look the example below:

    toolTipFormatFunction: function (value, itemIndex, serie, group, categoryValue, categoryAxis) {
    	var angleLabels = ['0', 'PI/6', 'PI/3', 'PI/2', '2PI/3', '5PI/6', 'PI', '7PI/6', '4PI/3', '3PI/2', '5PI/3', '11PI/6'];
    	return '<div>Value: ' + value + '<br />' + angleLabels[itemIndex] + '</div>';
    },

    Best Regards,
    Hristo Hristov

    jQWidgets team
    http://www.jqwidgets.com

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.