You haven’t used a CSV, you have used a JS.
Hi, with this method, I still have to manually change the index so it’s just the same as manually typing the country name. It’s not really making anything more automated.
Hi, I have a working demo of a more complicated multi-series spline and have tried to create a JSFiddle but I can’t get it to work, but this works perfectly as a webpage. Would you be able to take a look and see if you can understand? I am wondering how to do the same task as before – for the chart title, pull the country name from column 1 of the CSV – every fourth row as per the CSV. I tried the method you provided previously for the other chart but I can’t get it to work on this one. If I can provide any additional information, please just let me know: https://jsfiddle.net/w90ze7us/36/
Perfect! Thanks very much for all your help!
Hi Priyanka,
thanks for this, it’s great! But there’s just something strange happening with the X-axis. The four years are not being displayed correctly on the x-axis.
I’m also wondering if we can pull “exportFileName” from the CSV
Hi Priyanka, thanks for this example. I am trying to implement but I just get a blank screen when I try.
I am unable to create a jsfiddle because when I try to pull the data from a CSV file I just get a blank screen.
Is it possiblef for you to look at this bare-bones example to see how I can pull the chart title from the CSV?
http://www.globalhungerindex.org/csv/csv.html
I figured this out. I needed to use parseFloat instead of parseInt
Hi, I’m not asking about the padding now. I’m wondering how to add a legend to the graph itself? It seems to be impossible to align the legend separately, so we need to put the legend inside the graph, how could we do this?
Is it possible to fix this design issue in another way? i.e. instead of trying to align the ‘stackedbar’ with the scale above, could we integrate a scale into the stackedbar? http://www.globalhungerindex.org/sierra-leone.html
So, within the stackedbar, can we provide the values for each color?
Can you tell me what the padding is, so that I can match it to the grid I need to align to it? How many pixels top, right, bottom, left?
Hi Priyanka,
thanks for your reply. Unfortunately, I tried this already, but it doesn’t work because the website is fully responsive. The layout adjusts according to screensize, and the width of the container is based on percentages, not on pixels. Therefore, we cannot compensate for this unwanted padding with negative margin-left in pixels, unless we make an infinite number of ‘media queries’ for every screensize, which would be a huge undertaking, and slow the website down considerably. The much cleaner solution is to simply remove this completely unnecessary padding, which is what I was hoping was possible by posting in this forum. As in the example page, the graph must align EXACTLY and this is only possible if we can make the graph full-width with no padding. Otherwise, we cannot use CanvasJS and I think that would be a great shame, for such a silly reason as unwanted padding.
In your fiddle the credit is within a larger container in the bottom right corner, but the barchart should be full 100% width – the credit should not be outside. Am I explaining clearly?
Hi, I added the setting, but it’s still not looking as required – there is lots of padding to the left and right. I can fix the top padding by setting a negative top margin but I can’t get rid of the left and right padding with CSS: http://www.globalhungerindex.org/sierra-leone.html