Most voted "chartjs" questions
Use this tag when the question involves creating, editing or maintaining graphics created using the Chartjs library. This open source library uses canvas (HTML5) and javascript for graphic creation.
Learn more…108 questions
Sort by count of
-
1
votes1
answer1329
viewsHow to display chart values in chartJS without mouseover?
var chartData = { labels: [<?php echo html_entity_decode($nomes) ?>], datasets: [{ label: 'Desempenho global (Todas limpezas efetuadas em <?php echo $anoAvaliado ?>)', data: [<?php…
chartjsasked 6 years, 1 month ago Vinicius Avanzi 47 -
1
votes1
answer552
viewsHow to add caption to a chart using Chartjs?
I created the following chart: var data = [ { value: 300, color:"#F7464A", highlight: "#FF5A5E", label: "Red", subtitle: "texto" }, { value: 590, color: "#46BFBD", highlight: "#5AD3D1", label:…
-
1
votes1
answer1258
viewsHow to fix the percentage on top of the chart using Chartjs?
I have the following chart: var chartData = [{"visitor": 39, "visit": 1}, {"visitor": 18, "visit": 2}, {"visitor": 9, "visit": 3}, {"visitor": 5, "visit": 4}, {"visitor": 6, "visit": 5}, {"visitor":…
-
1
votes0
answers78
viewsPutting dynamic legend on graphics with Chartjs?
I am trying to put subtitles dynamically in my graphic, however all the examples I have seen on the Internet so far are directed to the frontend part (with HTML or Javascript), while in my case the…
-
1
votes1
answer37
viewsDisplay array inside the chartjs
I wonder if you could help me with the following situation: I have a column called event type , in it after completing a form will be inserted some of the 4 items: Collision, PT, THEFT, Theft. I’m…
-
0
votes1
answer93
viewsOrganize Chart bar by date
Using the Chartjs, I am generating a bar graph comparing the current and previous month, the day and amount of the payment made. The problem is that the Labels have a range from 1 to 31, the chart…
-
0
votes2
answers734
viewsHow to display formatted values in the chart
I use the following library to generate the graphs: http://www.chartjs.org I have the following function to format money with semicolon (taken from an answer here in the OS) which returns the value…
-
0
votes1
answer76
viewsChartjs to Kendo-ui
I’m changing from the Chartjs to the Kendo-ui. (My company has the license) I’m having some trouble customizing the Radar Chart I’m trying to use. 1) Remove lines that divide the graph. The cross…
-
0
votes2
answers410
viewsDecrease the number of bars on the Barchart Chart js chart
How can I decrease the number of bars to be displayed according to the month we are? Ec: currently our month is 11 (Nov), so I would like to present only the first 10 columns of the chart.…
chartjsasked 8 years ago Rodrigo Segatto 743 -
0
votes1
answer64
viewsShow chartJS chart even if you don’t have data
There is a way to display the columns of the Chartjs Barchart chart, even if they do not have data to display?
chartjsasked 8 years ago Rodrigo Segatto 743 -
0
votes1
answer102
viewsChartjs rotate text
I would like to know, I have a text created with canvas in chartJS]. How to rotate the text, the same being vertical in the center of the line. I tried with Rotate, but the text disappeared from the…
-
0
votes1
answer299
viewsChartsjs export PNG automatically
I need to export a chart co Chartjs (version 2.7) to PNG that I got on: https://jsfiddle.net/uabczmxa/ The only problem I need to push the button. Would anyone know what to modify in javascript? At…
-
0
votes1
answer365
viewsChart.js Different color for Negative/Positive Chart bars
Chart js.: Trying to put one color for positive values and another color for negative values on the chart. Works well if there is at least one negative value: Behold…
-
0
votes1
answer303
viewsChartjs with dynamic dataset
I need to create a dataset dynamic where the data will be filled through a query in the database, this data may generate N bars to be plotted then the dataset needs to be created according to…
-
0
votes2
answers124
viewsChartjs + mysql + php (month entries)
Guys, I have a user registration table. I am creating a chartjs to show on a bar chart the number of registered users per month. The mysql query would only have to return me 2 columns (MONTH AND…
-
0
votes1
answer904
viewsChange Y-axis values in Chart js
How to change these values of the Y axis in Chart js, these values from 5 to 50 were automatically placed by the plugin, wanted to modify them.…
-
0
votes1
answer514
views"export 'default' (Imported as 'Chart') was not found in 'Chart.js'
When I give one import Chart from 'chart.js' this error appears on the terminal: "export 'default' (imported as 'Chart') was not found in 'chart.js' And those bugs on the console: Error in mounted…
-
0
votes0
answers9
viewsHow to change the color of the Chartjs Chart Colors?
Whoa, whoa, so... I’ve been working with Coreui (it’s a tamplate based on bootstrap-4 and React to create interfaces) in this, I wanted to implement a graph, and the graph from what I saw in the…
-
0
votes1
answer451
viewsUpdate div with Javascript or Angularjs - for IONIC
Hello, I have the following problem, I have a select with an onchange method I would like you to update a div. The reason for this is because I have a 3 graphics made in angular-Chart.js and…
-
0
votes2
answers284
viewsDar Foreach label on Chartjs / Canvas - Codeigniter
I have a problem here, which may be simple, I don’t know I’m using a frame for the chart, where I can put the boxes I want so that it will be displayed at each bar. Getting like this: Each item…
-
0
votes1
answer257
viewsRADAR CHART - Chartjs - View Sublabels
I am using the chartjs RADAR CHART (http://www.chartjs.org/docs/#radar-Chart). I wonder if we could do sublabels on the chart and how we would do that. The following code: jsfiddle.net/f794khyf/5/…
chartjsasked 7 years, 7 months ago Rodrigo Passos 3 -
0
votes1
answer211
viewsHow to import the Chart.js library into an ASP file?
I am trying to insert a chart with Chart.js into an ASP page (not ASP.NET). I saw some tutorials from Chart.js itself and found the following statement: You can download the Latest version of…
-
0
votes0
answers58
viewsDivision into chartjs categories
Situation: I have a chart that presents the performance of the user and the group according to some questions that were answered by them. Each question belongs to 1 module and has an identifier…
-
0
votes1
answer656
viewsTooltip Chart JS Line Chart
In the image follows Line Graph I have. I would like the tooltip to come out as an example below: 80% Instead of the way it is: 03 : 80 Graphic Code: $(function () { new…
chartjsasked 6 years, 11 months ago Rodrigo Segatto 743 -
0
votes1
answer901
viewsMedian Line JS Chart Line
I have a chart like the image below in Chartjs: It is possible to draw a straight line that shows the average of the values as in the image below? Graphic Code: $(function () { new…
chartjsasked 6 years, 11 months ago Rodrigo Segatto 743 -
0
votes1
answer517
viewsPass data to viewbag from controller to view using Chart.JS
I am trying to pass the data from a list to a viewbag, but it is not returning correctly in the view. My model and control: public class DataPoint { public String nome = null; public double y = 0;…
-
0
votes1
answer364
viewsImprove visual information on Chart.js
I am developing a system and I use Chart.js to generate my graphics. However, at the level of usability, it is bad, because it does not show all the information of the columns. Looking at the above…
-
0
votes1
answer345
viewsPosition plots and values
The code for the chart is in HTML. In the code below, there are these Abels: ["Área 2","Área 3","Área 7","Área 5","Área 10","Área 8","Área 11","Área 9","Área 1","Área 14"] According to the date…
-
0
votes0
answers287
viewsShow graph sum of objects - Django/Python/Sqlite
How to show a graph with the sum of objects with Django/Python/Sqlite? In this case we have 'internal boxes' (y-axis) for 'teams' (x-axis) that are rendering'internal boxes' values for each 'team'…
-
0
votes1
answer1299
viewsChartjs. How to adjust the graph height according to table size? Ionic 3
I’m developing an application in Ionic 3, where I consume data from an API and display the data on a horizontal graph. The amount of data returned by the API is not standard, so sometimes the height…
-
0
votes1
answer765
viewsReturn label chosen when clicking on some column of the chart - Chart.Js
I have a Dashboard made in PHP and use the library Chart js.. In Dashboard, I have some graphics that are fed in PHP, as in this example: And I have a question, when I click on some column of the…
-
0
votes0
answers227
viewsGenerate chart using Chartjs in Express
I am trying to render a chart using Chartjs. I am using nodejs (Express) and mongoDB. The idea is to take the database data, go to the front, and from that, render the graph. I already have some…
-
0
votes0
answers2200
viewsUnexplained Error, Uncaught Syntaxerror: Unexpected end of JSON input
I’m making a chart and I’m using Chart.js, PHP and jQuery. I managed to run with the correct information, but after a while it stops working and presents the following error: Uncaught SyntaxError:…
-
0
votes1
answer414
viewsHow popular is Chartjs Chart with Vuejs and Axios?
I’m not getting popular my chart with data vintos of an api, can help me, I don’t know what I’m doing wrong! <template> <div class="py-1 bg-light px-5"> <div class="col-12 my-2">…
-
0
votes0
answers419
viewsHow to readjust the label of a Chart js chart?
How do I adjust the font size of the label or place a line break? The text is not fitting in full, for monitor 1080 fits, but 720 happens this. My code: <script> var myChartcaixa = new…
-
0
votes1
answer779
viewsHow to format monetary values to be displayed in Brazilian format with chartjs
How to format monetary values to be displayed in Brazilian format with chartjs, in the tooltip and in the Y axis of the chart below I wanted to display : R$199,99 e R$2.888,99 But I didn’t find this…
chartjsasked 6 years ago Daywison Ferreira Leal 167 -
0
votes1
answer134
viewsError creating graph with API data - Axios/Vue
Hello, I’m building a graph that collects meteorological data from the city of Curitiba through a API reset, however nothing is collected and so the graph is not created, I’m using Vue/ Axios for…
-
0
votes0
answers37
viewsSetting in charjs charts
Good morning guys, I have a graph that has a variable with 100 values, but when the chartJs will display it abstract and displays less points than it should, causing the graph to be half broken as…
-
0
votes0
answers30
viewsValues in Graphs
How do I make values appear next to the bars on the graph? var ctx = document.getElementById('desafios').getContext('2d'); window.myHorizontalBar = new Chart(ctx, { type: 'horizontalBar', data:…
chartjsasked 5 years, 10 months ago Alexandre Prezzi 89 -
0
votes1
answer502
viewsput Subtitle on Chart.js
I am working on a chart, and I am trying to put a Subtitle that varies according to the value that the user chooses. I didn’t find in any doc how to do this, and I tried to use Subtitle:{text:}, but…
-
0
votes0
answers113
viewsNg2-Charts Angular 2 - Update is performed on the chart, however, with empty data
I’m trying to update a graph using ng2-chartjs in Angular 2 (specifically Angular 7.2.0). When updating, the graph is resized, but the line of the graph is not drawn. To be clear, here’s what…
-
0
votes3
answers1178
viewsUncaught Referenceerror: Chart is not defined
I’m following the documentation Chats.js to implement graphics in my code the structure of my HTML is very simple <html> <head> <script type="text/javascript"…
-
0
votes0
answers88
viewsUpdate span in Chart.js Component Graphic Display Event
Hello, I’m creating a component in Vue.js to generate a group of dynamic charts, the values are still static, because I am still shaping. The current problem is I want to be able to update a…
-
0
votes1
answer119
viewsChange graphics colors with chartjs
Guys, I’m using Chartjs to create a Dashboard and I wanted to change the colors of the graphics. I found the Patternomaly library that assists in these changes, but I am not knowing how to import in…
-
0
votes1
answer213
viewsHow to increase bar thickness in Chart.js?
I am using Chart.js in React and would like the bars on my chart to be thicker without piling up. Next is my component rendering the graph: import React from 'react'; import { HorizontalBar } from…
-
0
votes0
answers25
viewsng2-char: How to show the percentage inside the graph?
I’m using ng2-Chart to generate the graphics. The problem I wanted to put the percentage or even the values inside the graph, but I couldn’t do that. In [options] step a plugin I saw the people on…
-
0
votes1
answer62
viewsCharts.js Problem to bring Data to the chart!
I have a Google Charts chart that works perfectly bringing the database data through ajax, but I tried to do the same with Charts.js and I can’t. I would like to know how I put real data on the…
-
0
votes0
answers17
viewsProblems with Chartjs
Hello, good morning!!! I’m creating a graph that pulls data from a database and shows it on the screen, with php, mysql, ajax, Chartjs and jQuery. When I use only one dataset, everything works fine,…
-
-1
votes2
answers2381
viewsLabel and Caption on Chartjs Doughnut Charts
Would anyone know how to include Caption and Label above the chart in this type below? http://www.chartjs.org/docs/#doughnut-pie-Chart I created mine, but I’ve already entered all the options of the…
chartjsasked 8 years, 9 months ago Rodrigo Segatto 743 -
-1
votes1
answer185
viewsGraphics with PHP
I’m having trouble generating charts using data from the bank. I have a query in the database that generates an array as a result. (Follow below) <?php require_once './setaqueryDash.php';…