I am trying to place the axes label in a barchart using the "Placed" command in a position different from the end of the axis. It works in other graphics, but not with BarChart.
Is there a workaround?
Related
Is it possible to change x-axis label orientation like marked area on the screenshot? I was trying rotate labels with afterCalculateTickRotation but they weren't flipped. Mirror option doesn't work also.
Example code
I managed to do what you are asking for but it's not beautiful because chart.js lacks support to do it properly. So I solved it with some hard coded padding.
https://codesandbox.io/s/vue-template-4ygr1
It's the minRotation and maxRotation you should work with. The labels anchoring point should shift when the rotation goes below zero but they don't. Instead they rotate into the chart but this can be avoided with padding.
A side effect of the padding is that the legend placement broke so i put it in the top instead.
Another unwanted behavior is that the text is aligned to the right. There is an open issue about that: https://github.com/chartjs/Chart.js/issues/4193
I would like to implement a scatterplot over timeline using plotly.js, similar to the image below.
Plotly takes in x and y values to plot the chart. But I will be plotting x-values(time) without any y-values. Is it possible to do so ? Or can I generate random values for y-axis ? Any suggestion or idea would be great.
I am using iOS Charts by Daniel Gindi.
I need to draw horizontal stacked area chart (Example). But I cannot find similar charts in examples of the library. I am trying to customise Horizontal Bar Chart like in example. But I cannot to avoid square corners.
How can I draw line instead of bars with squared corners?
Is it possible in this library or I should use another one?
Yes you can.
Use line chart instead ,and set drawFilledEnabled to true.
But the filled area is between line and x axis, so you may need to rotate the chart.
I've got a stacked bar chart with legends, but depending on the data selected, it becomes unreadable because of the space added around the bars and the series and the fact that the outer horizontal axis label won't rotate. I've tried as many things as I can think of, but nothing alters the spacing or the rotation on the outer axis. Picture 1 gives you an idea of what I mean. Main thing that would probably help is the rotation. Using VS2012 but not inline code. Any help appreciated.
I'm developing an html5 canvas image application where you could make basic transformation like 90º rotation, flip horizontal and vertical.
I use the following matrix to paint the image:
matrix.scale(flipHorizontal, flipVertical); // Where each flip could be 1 or -1
matrix.rotateZ(angle); // Angle could be 0,90,180 or 270º
Everything looks fine at the beginning but when I make a rotate90º and after an horizontal flip it just acts like a vertical flip.
Any idea how to fix it?
example http://img688.imageshack.us/img688/1570/73811955.jpg
Try this plugin
Demo: http://dmadan.in/imageflip.html
Source: https://github.com/dmadan86/imageflip
It works in both css3 and Canvas.
Cannot tell from the code snippet you have given. Could be a mistake inside the functions or when you call the functions. Might be something to do with how the axes are being handled.
A horizontal flip is a reflection in the y (vertical axis). After rotation the y axis of your image is now horizontal, so unless you correctly deal with the axes a 'horizontal flip' will reflect in the y axis which is now horizontal producing the image as given.