I'm trying to graph some data with RRDtool and I have problems with defining the exact graph command.
The kind of graph I want is something like this:
http://oss.oetiker.ch/rrdtool/gallery/gate.spamd.week.600.png - the blue graph.
I can not "cook up" the definition for creating a graph like the one which is light blue and is on the background. It's a something between a line and an area :) . Any ideas what can I try?
Thank you in advance!
I guess it is an area stacked on a transparent area or on a line ... in that way you can create a 'floating' area.
Related
problem screenshot
Hey guys, I'm having a problem: as you can see in the screenshot, there are some resolutions that the distance between the last and the second to last dates on x-axis is greater than other ones when you use a lot of data on that axis. Can somebody with a project like that test to see if this happens to every project? Probably this is the way Chart.js handles putting more elements on x-axis, but can I do something about it?
Thank you very much!
I'm using Baidu ECharts2 to visualise a dynamic amount of series (up to 100) as a line chart.
The issue I face is the legend overlaps the graph in case if the series are too many.
I spent good 2 hours in searching the documentation and reading, but cannot figure out any way to set the graph position (y/y2 top/height).
It seems the chart consists of different elements (legend, toolbox etc), but none of them seems to be the graph itself.
An example I found showcases a fully responsive way to position pie charts, but this is not applicable in my case:
https://ecomfe.github.io/echarts-examples/public/editor.html?c=doc-example/pie-media
I'd be grateful if someone has more experience with ECharts and can tell me way to move the graph down by y and set a height.
Thank you!
Your best option may be to set the legend type to scroll so it fits on one line.
legends.push({
type: 'scroll',
show: true,
data: myData,
...
});
You may also be able combine Ovilia's and Zain's solutions to move the grid down to leave space for the legend. Unfortunately that would require a way to determine the legend's size before setting the chart's container size.
You can set grid position to make it.
In ECharts 2, you may set grid.y, grid.y2, or grid.height.
In ECharts 3, you may set grid.top, grid.bottom, or grid.height.
I'm currently developing a Qt desktop application using the Q3DScatter class. I'm inspecting Qt's 3D Scatter example project and I tried to modify the data item set to plot my own data. The data is plotted except that one axis is not well scaled and my 3D plot looks really messy. I'm looking for a way to adjust this axis. I've tried to change the range and the segment count of the axis, I even tried to set the "AutoAdjustRange" of the axis to true, but nothing seemed to solve the problem.
Would really appreciate some help.
PS: Here's a screen capture of what my 3D scatter graph looks like (the "messy" axis is shown with the red arrow)
I figured this out by creating a CustomFormatter class by subclassing QValue3DAxisFormatter and reimplementing some of its functions (I followed this tutorial). Then I set up my axis formatter to my custom formatter (m_graph->axisZ()->setFormatter(cf);).
Subclassing QValue3DAxisFormatter will not work: it determines where ticks and labels are placed, but not how large the axex actually are.
To do that, you can set the (horizontal) aspect ratio, that is a property of Q3DScatter. The following settings will make the data into a cube volume:
plot->setAspectRatio(1.0);
plot->setHorizontalAspectRatio(1.0);
When using TGraphErrors, the error bars appear as crosses, in the absence of significant X errors and many, many data points (such as MCA with 16k bins or so) I'd like to be able to remove the single points and single error bars and graph the error as a shaded region bounding the curve from above and below.
But I'm still a rank beginner at using ROOT, and I cannot figure out how to leverage TGraphErrors to do what I want. Will I need to instead use a TMultiGraph instead (and calculate the above and below bounding curves) and if so how can I control the shading region?
Something like the below would be along the lines of what I'm looking for. Source
Take a look at the TGraphPainter documentation which gives a few examples. One way is to draw the TGRaphErrors using option 4:
A smoothed filled area is drawn through the end points of the vertical error bars.
You will probably find that to get the final plot to look as you want, you have to draw the same graph multiple times - once to get the shaded region, then again on top to get the central curve.
This blog post gives a working example. It's written in PyROOT, but can be easily adapted to C++.
Skewing x and y coordinates doesn't give that kind of effect. Any ideas on how to achieve this kind of effect? I already use cccamera but there are no examples on how to properly implement this. This image btw is from cocos2dx tried the c++ code still didn't work
I feel I need to share this once and for all. So this is how camera works when you want a slanting ,45degree or pseudo3d view of your background :
First set your director to 3d perspective
[director_ setProjection:kCCDirectorProjection3D];
If you only want some of the sprites to appear this way then remember this
all nodes have camera (cocos2d v.3 doesn't seem to have it anymore I don't know why)
so you do this:
[mysprite.camera setEyeX:0 eyeY:-40 eyeZ:10];
[mysprite.camera setUpX:0 upY:0 upZ:1];
Play with the values that fits your need. Hope it will help others!