Questions tagged [plottable]
Plottable (also known as Plottable.js) is a JavaScript library of modular chart components that allows you to create interactive web charts. It is built on top of D3.
42
questions
0
votes
1
answer
77
views
SwiftUI Charts extension Image: Plottable
Is there any sensible way to create sth like extension Image: Plottable and pass to .value inside BarMark. Or there is any other possibility to have images below charts instead text?
I try sth like ...
2
votes
1
answer
429
views
How to use Core Data with Swift Charts?
I'm doing FetchRequest
@Environment(\.managedObjectContext) var managedObjContext
@FetchRequest(sortDescriptors: [SortDescriptor(\.date, order: .reverse)])
var day: FetchedResults<Item>
...
0
votes
3
answers
813
views
ReferenceError: window is not defined after installing my npm package containing a D3 chart on my Next.js repo
I have 2 repos, one that houses all my components that gets packaged and uploaded to a private feed, and one that consumes them. Both repos use React and TS with the repo that consumes the package ...
0
votes
1
answer
40
views
Plottable.js entityNearest not giving me the nearest entity
Im implementing the code below in a React, Typescript project.
When hovering over my graph I don't get the nearest entity its roughly 5 years off, on my x-axis(time).
I've tried switching out ...
0
votes
1
answer
38
views
Extracting value from promise after fetching data from a locally stored .csv file to pass into a Plottable.js table
The project I'm trying to achieve the desired result within is a TypeScript, React project that's running Storybook.js.
I have a csv file that I've stored in the public folder of my React application. ...
0
votes
1
answer
37
views
How to plot in spyder3 via matplotlib?
In the beginning I was able to view the plot in the upper right window of Spyder3 (variable explorer)
But now nothing is being plottet anymore (no errors)
I wonder if theres something wrong with my ...
1
vote
1
answer
101
views
Plotly.js - multilayer time axis
Is there a way to create time axis using Plotly.js similar to Plottable.js' solution?
Example here.
I plan to move to Plotly.js but really fell in love with this presentation of a time axis and as ...
0
votes
1
answer
131
views
Why is Plottable not showing the full chart?
I have no errors (finally) but all I get is an x-axis without any data. What am I missing? I am running this from the Live Server plugin in vsCode. Also, there are two tags for plottable: plottable ...
0
votes
1
answer
159
views
How to Import Plottable.js
I am fairly new to javaScript. I am having issues finding out how to import and use the Plottalbe.js (along with D3 that is part of it) libraries. Can anyone show me a working example of an HTML and ....
5
votes
2
answers
5k
views
Include bootstrap.js external script in Vuejs single-file components
I'm using several external libraries to build charts with tooltips within a vue app. I'm using single-file components
I've got a working fiddle, but haven't been able to translate it into a working ...
2
votes
1
answer
196
views
Set tooltip on a plottablejs linegraph from Angular directive
I got a angular directive that displays a plottable line graph. But I need to set tooltips whit the value when the cursor hovers the line im plotting.
I got something like this:
var plot = new ...
1
vote
0
answers
1k
views
Replacing the $ (Dollar sign function) from JS in Typescript does not work
I have an angular-2-application written in typescript which works pretty well; however, I stumbled upon this Problem for which the various related answers to the $-function did not help me.
I also ...
0
votes
1
answer
62
views
Unable to parse objects
var data = [{
x: 'A',
y: 3
}, {
x: 'B',
y: 2
}, {
x: 'C',
y: 4
}, {
x: 'D',
y: 3
}];
var xScale = new Plottable.Scales.Category()
var yScale = new Plottable.Scales.Linear()
var xAxis ...
1
vote
0
answers
48
views
Plottable.js Custom Formatters
Does anyone know how to achieve custom formatting when using Plottable.js. You used to be able to pass in a function to the Custom() method to format your numbers, like so:
let customFormatter = new ...
1
vote
1
answer
40
views
Plottable.Plots.Rectangle creating rects with 0 width
I have the following data:
[{
"date": "2016-10-12T00:00:00.000Z",
"parameter": "end_brick_temperature",
"value": 61.3,
"color": "green"
}, {
"date": "2016-10-12T00:00:00.000Z",
...
1
vote
1
answer
145
views
plottable.js bar graph rendering off the axis
I can't understand why such a basic bar graph goes off the page. The axis limits seem to take only the smallest value. Here's a js fiddle showing my problem and the code is pasted below as well.
http:...
0
votes
1
answer
260
views
Bar graph on time axis with plottable.js - bar positions
How to I can align bars with related dates with plottable.js library? First bar data are from Wed 7 and second from Thu 8.
Here is JSFiddle example: https://jsfiddle.net/50yq46cm/3/
function ...
9
votes
1
answer
423
views
How to add horizontal line over y-axis in Plottable.js
I have the following running code in JavaScript's Plottable.js.
var data = [{ x: 1, y: 1 }, { x: 2, y: 3 }, { x: 3, y: 2 },
{ x: 4, y: 4 }, { x: 5, y: 3 }, { x: 6, y: 5 }];
var ...
0
votes
2
answers
58
views
How can I determine if the right mouse button was clicked in a Plottable chart?
The Plottable Click Interaction doesn't pass the callback any sort of event (synthetic or otherwise) so I can't figure out a way to determine which button was clicked.
Has anyone wired up the right ...
1
vote
1
answer
143
views
How do I check the original value in label formatter using plottable.js?
I have a relatively simple bar chart using Plottable. All the bars start at 0 but the third bar can be negative and changes colors. To display in this way, for the third bar I use Math.abs(value). ...
1
vote
1
answer
323
views
Plottable.js line chart not display
The chart is black as shown in the attached photo. This is a chrome extension. When I click on inspect on the popup, plottable/d3 elements are defined so it seems that plottable is being made ...
1
vote
1
answer
163
views
How to color GuideLine in Plottable.js?
I'm trying to find a simple way to color a GuideLineLayer from Plottable.js.
I tried the following so far.
1) trying to use attr() inside onAnchor()
This adds the attr to the g element containing ...
2
votes
2
answers
186
views
Arrows on Line Segments
I'm using Segment Plot to show multiple lines on the chart. How can I make these lines have arrows on their ends?
1
vote
1
answer
120
views
How to make two histogram plot using independent scale under Javascript Plottable.js
I have the following code.
Which if you click the run button you can find two
histogram plot side by side.
But the scale of the two is different. First panel has scale 10^80
and another one 0 to 1. ...
4
votes
1
answer
453
views
How to make label in histogram respond to dynamic user input
I have the following working code. It takes the input data and display the histogram based on a threshold.
If you run, the code below, the code is working to the extend
that the histogram changes as ...
2
votes
1
answer
162
views
Pie chart animation when data changes in plottable.js
I am trying to animate a pie chart when data changes. Below is a code snippet
var piePlot = new Plottable.Plots.Pie()
.addDataset(dataset)
.outerRadius(function() { return ...
0
votes
1
answer
303
views
Custom animation in plottable.js line chart
I am trying to use custom animation in plottable.js when data updates.
Below is my code : -
<script type="text/javascript">
var xScale = new Plottable.Scales.Category();
var yScale = ...
0
votes
1
answer
231
views
How to enable qtip2 in Piechart made by Plottable.js/D3.js
I have this code, which tried to enable qtip in plottable.js
var store = [{ Name:"Item 1", Total:18.73424242 },
{ Name:"Item 2", Total:7.34311 },
{ Name:"Item 3", ...
0
votes
1
answer
716
views
How to format number precision to two digit decimals in Plottable.js Piechart labels
I have this code:
var store = [{ Name:"Item 1", Total:18.73424242 },
{ Name:"Item 2", Total:7.34311 },
{ Name:"Item 3", Total:3.1235535},
{ Name:"...
0
votes
1
answer
80
views
'Invalid value for <path>' error while making pie chart under Plottable/D3.js
I have the three parts code (HTML, and JavaScript).
They can be downloaded here:
index.html
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<!-- Later add ...
3
votes
2
answers
479
views
How to display a legend in Plottable.js multiple plot
I have the following code:
var indata = [{
'sample': "Foo",
"pies_pct": [{
"score": 6.7530200000000002,
"celltype": "Bcells"
}, {
"score": 11.432763461538459,
"...
0
votes
1
answer
116
views
How to make two plots side-by-side using JavaScript Plottable
With the following script I tried to make the side by side pie chart
var pies;
var indata = [
{ 'sample' : "Foo",
"pies_pct":[
{
...
0
votes
1
answer
66
views
Conditional removal of label from Javascript Plottable Piechart
I have the following code:
window.onload = function(){
var store = [{ Name:"Item 1", Total:18 },
{ Name:"Item 2", Total:7 },
{ Name:"Item 3", Total:3},
...
3
votes
1
answer
609
views
How to create candlestick chart in plottable.js
What is the best way to create candlestick chart in plottable? I would like to do something like this image on wiki:
Wiki example
I was thinking about using stacked bar plot and styling it with css. ...
0
votes
2
answers
585
views
How to use your own color palette in Plottable.js pie chart
I have the following code:
var scale = new Plottable.Scales.Linear();
var colorScale = new Plottable.Scales.Color();
var data = [{ val: 1 }, { val: 2 }, { val: 3 },
{ val: 4 }, ...
2
votes
1
answer
687
views
How to create Pie chart using Plottable.js
I tried to create a pie chart using Plottable.js.
Does anyone know how? I get confused on how to pass the value and put a label in.
Here is my sample data:
var store = [{ Name:"Item 1", Total:18 },
...
1
vote
1
answer
206
views
Create Plottable.js stacked bar chart using the same dataset
I am trying to create stacked bar chart using plottable.js from the same dataset. Is it possible?
Here is my sample dataset
var data = [{ x: 0, y: 1, m: 10 },
{ x: 1, y: 1, m: 9 },
...
1
vote
3
answers
972
views
How to resize chart in Plottable.js
I am using Plottable.js to draw chart on my page.
I would like to resize the chart when the window is being resized.
I've tried to set the size via css (as well as svg width and height attribute) ...
4
votes
1
answer
188
views
How to make qtip2 respond to dynamic user input
I have the following working code. It takes the input data and display the histogram based on a threshold.
"use strict";
var histograms,
thresholds = [];
var input_data = [{
"...
0
votes
1
answer
235
views
How to enable legend in Plottable.js Histograms plot
I have the following script. It simply plot the histogram
in the given data.
"use strict";
var xScale = new Plottable.Scales.Category();
var yScale = new Plottable.Scales.Linear();
var ...
1
vote
1
answer
373
views
D3 time axis like plottable.js
I have D3 web app and today I use a standard d3.svg.axis to display a time axis. I would like to change this to a time axis like the one Plottable implements, e.g. the Plottable.Axis.Time version.
...
2
votes
2
answers
834
views
Basic math 101 scatter plot with Plottable.js
How does one make a basic scatter plot like the one below using Plottable.js?
Is there something wrong with my JSON?
How to reveal the minus scales?
Would you have done anything else differently?
...