Questions tagged [visualization]

1

votes
2

answer
4.2k

Views

ggplot2 : How to reduce the width AND the space between bars with geom_bar

I understand that one can change the width of a bar in geom_bar using the width argument. That does work, but then it creates a larger gap between the bars. Is there a way to manually push the bars closer to together? Should I be manipulating the axis somehow instead? Here is an example, changing wi...
Alex
1

votes
1

answer
482

Views

toggling series of google chart on and off by clicking on legend

I have an area chart that has 6 series. I want the user to be able to click on the legend to toggle the visibility of a series. I found this example & have tried including it in my code below but nothing happens. Before adding this code if I clicked on one of the series in the legend the series woul...
mHelpMe
1

votes
1

answer
148

Views

Echarts4r : Create stacked area chart with percentage from total in tooltip

I need to make stacked area chart using the echarts4r. In spite of great examples on javascript I can't find the solution how to make the area chart stacked using R. Ideally it is also necessary to add to the chart the tooltip with percentage from total as in my example using highcharter package....
iomedee
1

votes
2

answer
31

Views

Add background solid fill to Altair graph

I like Altair a lot for making graphs in Python. As a tribute, I wanted to regenerate the Economist graph(s) in 'Mistakes, we’ve drawn a few': This is the code of a first shot: import numpy as np import pandas as pd import altair as alt df = pd.read_csv('http://infographics.economist.com/databank/...
cast42
1

votes
2

answer
57

Views

How to implement the makeApiCall() method after migrating Google Sheets API v3 to v4 with Oauth Authorization in Javascript

Google has build v4 of the Google Sheets API but the documentation of this is still at v3. There are no full examples of how to implement a simple OAuth authentication with Google Sheets API v4. I see a migration guide here and I also see a partial example here But a full example is nowhere to be fo...
Elnoob
0

votes
2

answer
17

Views

How to make separate mean+errorbar on top of a scatter plot & how to make a horizontal mean line?

I want to make a position_dodged scatter plot with means represented as horizontal lines (with error bars). I'm having trouble position_dodging the mean and error bars using stat_summary() and making the mean appear as a horizontal line. I want to show that the mean is different between the sexes. I...
CeC
0

votes
1

answer
19

Views

How can I visualise time series with coordinates?

I am trying to get this data plotted. I am not sure which package to use. Data looks like this in excel Time [4710.19 4710.21 4710.23 4710.24 4710.26 4710.28 4710.29] X [176.5 176.5 176.5 177 179 180.5 182.5 185.5] Y [222 227.5 237 247.5 263 278 296 314] I would like to ge...
Sarune Savickaite
0

votes
0

answer
7

Views

Python wordcloud can't present Hebrew

I am trying to create wordcloud to a text in Hebrew. The text is: את הסיפור שלנו סיפרנו לעצמנו כל הזמן. בכפייתיות. בעל פה. לפעמים התעייפנו עוד לפני שהתחלנו ובכל זאת סיפרנו במשך שעות. הקשבנו רוב קש...
okuoub
0

votes
0

answer
8

Views

Power BI sorting irrespective of number

I have one Power BI report that has bar graph in it. I need sorting to work out irrespective of the value that it is bringing in. For example, see the sample dashboard: The dashboard shows immigration population of certain countries from 1920-2010. There are few countries displaying negative values....
Romil N
0

votes
0

answer
4

Views

Grouped bar chart array indexing in tooltip and sort by within group values

I've been trying to learn Javascript on my own for data visualization in the past couple days and is working/struggling with a grouped bar chart. Chart working in progress: https://blockbuilder.org/lydiawawa/261aebe55bef8b556d257f3693cca37e x-axis: Drug Categories y-axis: Count of Drug Categories x...
lydias
1

votes
2

answer
91

Views

How to plot a table object in ggplot

Code : library(plyr) library(datasets) data('iris') iris$Sepal.Length size
baxx
1

votes
1

answer
108

Views

Increase Font Size of Chart Title in Altair

I can't figure out how to increase the size of the font for the chart title in Altair. My code will only change the font size for the axis titles, but not for the chart title. Here's what I tested out: data = df bars = alt.Chart(data, title='This is the Chart Title').mark_bar().encode( x = 'Feature...
Ragnar Lothbrok
1

votes
0

answer
622

Views

Cannot read property 'DataTable' of undefined in google charts

as the title saying im getting this error when trying to get charts inside function in another file like this functions.php function get_likes($catid){ require dirname (__FILE__).'/dbfunction.php'; ?> google.charts.load('current', {'packages':['corechart']}); a= ; b= ; c= ; i= ; ///// this i is...
Samir Daraf
1

votes
1

answer
92

Views

Working with google charts (want to get the value of column when click on the column)

I am working with Google charts. I want to get the value of column which is clicked. column name is showing in alert but I want get the percentage value also var chart = new google.visualization.ColumnChart(document.getElementById('divAgingReport')); chart.draw(data2, options); google.visualization...
1

votes
0

answer
46

Views

Is there a max. number of Google Charts on one page?

This is hunting me the last 1.5 hour. I am trying to add a 16th graphs on a page (from a total of 20th) and now the legends of all graphs are off. google.charts.load('current', {packages: ['corechart']}); google.charts.setOnLoadCallback(chart1); // Incidents google.charts.setOnLoadCallback(chart2);...
alex
1

votes
0

answer
22

Views

Container not defined when toggling column data in Google Charts

Displaying an Area Chart with data. Initial chart draws and displays fine, but when I try the onclick check boxes to remove a column and redraw, I get 'Container not defined' error. The #chart element is contained in the base HTML and DOM, not being added later. The onclick events fire, and I can lo...
mrpatg
1

votes
0

answer
42

Views

How to select/deselect data for columns in Google Charts?

How can I add selection boxes in the legend which selects/deselects the data to be displayed? For instance say I want to deselect t2 to not appear in the stacked columns? google.charts.load('current', {packages: ['corechart']}); google.charts.setOnLoadCallback(drawChart) function drawChart() { va...
alex
1

votes
0

answer
357

Views

Google chart pagination

I have problem with google charts. I am using ColumnChart to show my data. I wan t to implement pagination on charts. This is my chart: I want to implement something like this: This is my option for chart var options = { width: '100%', height: '100%', chartArea: { width: '90%', height: '90%', }, bar...
mrkibzk
1

votes
0

answer
49

Views

Improve 3D animation for didactic usage

I am preparing some didactic materials about optical illusions. For this I decide to play around three.js. I’ve done illustrations for structure-from motion effect. The idea of this effect is that our visual system is always working in situation of insufficient information and should add lacking d...
zlon
1

votes
1

answer
104

Views

Google Charts LogScale not working

I'm using Google Charts to make a bar graph and I'm trying to get the graph to use a logscale on the vertical axis but it's not working for some reason. I've tried using logScale and scaleType but neither of them work. Here's my code: google.charts.load('current', { 'packages': ['bar'] }); google.ch...
Neuro
1

votes
1

answer
350

Views

Google Charts - Dashboard toggle data series on/off [duplicate]

This question already has an answer here: How to add colors to spefic columns in Google Charts 1 answer As always I appreciate the experts here! The check box should toggle the 5th column in the chart. (red goal line) Function colToggle() in general is working because the switch gets me to the righ...
cmill
1

votes
2

answer
468

Views

Hide axis tick values under a certain range in d3.js

I'm looking for a way of hiding axis tick values that fall under a certain range of values in D3.js. For example, let's say my y axis shows values from 0 to 100, showing every 20 of them (0, 20, 40, 60, 80, 100). Now, how would one hide certain tick values from showing up? So if I want to hide value...
Akbar
1

votes
0

answer
101

Views

Google visualization chart on server side c#

I need to export the geo chart generated using google visualization into an image. One way is to go to the client side, generated and render the geo chart and then use getImageURI() and using the result generates an image on the server side. But, is there a way that I can skip going to the client si...
Siddhannt Arora
1

votes
0

answer
134

Views

How to print two Google Charts in one PNG image?

I'm writting a code which shows two different Google Charts in one XHTML page. I need to put a button that export both graphs to the same PNG file, one above the other as they are shown. To export one single chart is easy and is already done; Google documentation teaches that in here with only minor...
Momergil
1

votes
0

answer
36

Views

How to plot several lines plots inside each tile of a SOM?

I'm currently working on SOM vizualisations. This is a SOM map with codes plots generated by using kohonen package Shortly, each circle is a neuron and inside each neuron we plot all the variable in a spectra shape. This plot is obtain by som_obj$codes[nameoftheneuron] (som_obj is the return value o...
Olorin.G
1

votes
1

answer
17

Views

Google Charts adding unwanted text

I'm made a integration with google Spreadsheets, works really well, but on the Y-AXIS on the BARS and LINES chart, a 'General' is printed with the range number! My code: // Load the Visualization API and the corechart package. google.charts.load('current', {'packages':['corechart']}); // Set a callb...
Erick Amaral
1

votes
0

answer
148

Views

Efficiently plotting large number of pictures on a grid in Python

I've implemented a program that outputs a very large number of tiny images next to each other in a certain way. Currently I'm using a grid of 50x50 but I want to be able to increase this and my current code becomes really slow in that case. I've read from several people online this is because of the...
user3343378
1

votes
1

answer
39

Views

Google visualisation with Chartrangeslider and data import from Google docs spreadsheet

I have the problem, that I dont manage to implement my data from a google spread sheet when using dashboard environment with chartwrapper and controlwrapper. I used the piechart example from the google charts website (https://developers.google.com/chart/interactive/docs/gallery/controls) and tried t...
Christoph Seiffert
1

votes
1

answer
65

Views

Legend in Google Chart not loading properly

I am using Google Charts for displaying data and the graph loads properly, but the legend is not loading properly. This is the jsfiddle link to my chart. Please check the legend position and you will understand my error. Below is my code, html test chart this is the test tab my js graph(); function...
Arigato Manga
1

votes
0

answer
136

Views

Google chart, annotations and label issues

I'm generating a graph using google chart, however I have several problems. First: Currently an annotation is displayed in the second series in which it shows the place in the ranking. However, if there is more space in the second series (gray background) the text is moved lower or disappears comple...
Hubert Szkudlarek
1

votes
1

answer
58

Views

Pie chart not showing slice

I create a pie chart using google services. the problem is that i want to show credit and debit in pie chart, but output comes only in one color. Here is my query. $data = mysqli_query($link, 'select SUM(pay_payable) as debit, SUM(pay_paid) as credit from purchasers_payment where p_id = '$pur_id'');...
umar Aslam
1

votes
1

answer
417

Views

Responsive Google Donut chart with responsive Pie hole?

I am trying to make my google charts responsive and this help me out a lot: as I am using bootstrap as well. But with my PieChart I added an overlay in the center piehole. How do I make the piehole overlay responsive as well, like in the code preview it was in the center but now it is way off and re...
user9191816
1

votes
0

answer
122

Views

Fade color of connected nodes on button click in d3

I want to change color on button click, in JavaScript(d3.js), only if node is connected with others. I'm following this example https://bl.ocks.org/mbostock/929623: rect { fill: none; pointer-events: all; } .node { fill: blue; } .link { stroke: #999; } var width = 960, height = 500; var fill = d3.sc...
Asia
1

votes
0

answer
269

Views

Line chart with radio button and multiple series

I would like to create a line chart like this, with the difference of having radio buttons instead of a dropdown selector. This is my data.csv file: CODE,YEAR,MODALITY,VALUE AB,2000,first,15 AB,2000,second, AB,2000,third,33 AB,2001,first,20 AB,2001,second,25 AB,2001,third,87 AB,2002,first,6 AB,2002,...
1

votes
0

answer
184

Views

d3js: display tips coorectly after zoom

I'm trying to write an example using D3.js where images lay on a static background. I can move the background and zoom and I can also move separate images (something like this but with images). Also, I need to display a tooltip when the mouse is over an image. Here what I have tried with d3js v4: Pr...
mrgloom
1

votes
1

answer
232

Views

Google Visualization DataTable Change background color

everyone! I have using google visualization datatable to create a simple orgchart but I want to change background color dynamically like the following. I have hardcode the row index to change backgroud color. How to get this row index using for loop or other methods? Please help!!! function OnSucces...
user1735815
1

votes
1

answer
25

Views

google-visualization Class ChartOptions get-method

Refering to https://developers.google.com/apps-script/reference/charts/chart-options it is possible to use the method get(option) for an Class ChartOptions object. Using this code: var allChartOptions = gcharts_LineChart.getOptions(); console.log(allChartOptions); I get the log: Object { title: 'ave...
N. Her
1

votes
1

answer
28

Views

How to get Google Charts to sort and give me correct answer

Okay so I have some data and I need to get Google Charts to sort 3 types of answers from several lines of code. How do I do that with my current code: google.charts.load('current'); // Don't need to specify chart libraries! google.charts.setOnLoadCallback(drawVisualization); function drawVisualiza...
Chancellor Purvis
0

votes
1

answer
185

Views

google-visualization-table-page-numbers background color change

I'm trying to change what I would call the footer background color where the google-visualization-table-page-numbers go. I would like the background color to extend the entire width of the table. I am hoping someone can help me find the correct solution.
Chris S
1

votes
1

answer
233

Views

One or more participants failed to draw() with google dashboard

I tried to implement a google dashboard prototype with a category picker and a pie chart, while displaying the datatable. However, even while following the sample code from the documentation (https://developers.google.com/chart/interactive/docs/gallery/controls#5-create-control-and-chart-instances),...
nilesguo

View additional questions