How to implement this stacked line chart in MPAndroidCharts or iOS-Charts - swift

I have a number of charts/graphs created with the ported MPAndroidCharts project iOS-Charts by DanielGindi but I'm getting a request and I'm just not sure it's technically possible with things as they exist today.
I have used gradients but not sure if there's a way to kind of have it just be a 2 sided/colored gradient instead of a gradual fade. I have not created or seen an example of a dotted line coming through the existing chart but assuming zoom isn't a possibility I could hypothetically float a view over the top of it but I'd definitely prefer to have it in the native charts code/implementation.
The first graph is showing how much a user plans to have at retirement, the two shades of green represent different sources of money, the dotted line represents their spending from retirement to their estimated time of death.
The second graph is showing the gap between how much a user plans to have at retirement and how much we project they're missing compared to what they have and how that will look across the time from retirement to estimated death.
Thoughts?

It looks like a line chart with three lines and each with a solid fill.
In the top one, the dashed line graph has a white stroke and no fill, but in the bottom one, it has a black stroke and gray fill.
In the top one, the dashed line should be z-ordered to be on top, but in the bottom one, it should be z-ordered to be on the bottom.

Related

Why does AWS CloudWatch dashboard widget does not respect scales when drawing two lines?

I'm new to AWS and CloudWatch.
Here is a screenshot of a CloudWatch dashboard showing two parameters related to a Dynamo table.
As you can see in the pop-up the value of the sample for the orange timeseries is 2,252 while the value of the sample for the red timeseries is 7,000, yet the red chart is drawn under the orange chart. If you check the scale on the left, it seems the red series is the one that get drawn correctly, while the line of the orange one is somehow "inflated".
Can you please help me understand what is the reason behind this?
It looks like your mouse hover point data and the popup data are out of sync. Just a UI glitch.
The popup is showing 09:57 and probably on the chart at 09:57 those are the correct values.
The hover point you chose is a particular peak and is at what time? The last digit is cut off from the display but it's definitely not a 7! Looks like "09:50" maybe?
Minor UI glitch is my diagnosis.
Eventually I come up with this different set up, where one of the series has values mapped on the left Y-axis, while the other series has values mapped on the right Y-axis.
The main drawback is that the two series are not directly comparable, but at least the difference in value is more evident.

Miscoloured lines in rule-based layer styling in QGIS

I'm styling a vector layer of roads and have noticed that a small subset of lines appear to be going 'rogue' and ignoring their line colour styling. They still obey the line stroke and width style however but insist on being yellow instead of the desired colour.
I've added a separate rule for one of them and it definitely 'catches' the correct line segment and restyles it in every way EXCEPT for the colour which stubbornly remains yellow.
Can anyone provide me with any clues as to what is going on here?
That line (or lines) are "selected" - You have one of the selection tools active and have clicked on the line. See the manual for more details, you need to click on the clear selection tool
to remove it.

pie chart but in another shape

I just wanna ask if it is possible to make a pie chart but in another shape.
An example would be say there were two candidates who ran for governor in a state. I would want to show the results in a chart. I want the shape of the chart to resemble the shape of the geographical location of the state.
I did some digging and this is the only one that showed up which may help me(but not really) https://forums.adobe.com/thread/988130
As your adobe thread implies there are (at least) three issues to consider:
1) you want to show the votes each candidate received as a portion of the area of the state. If your state is nearly square, you could overlay a grid and assign each candidate a number of grid cells according to the votes they received. If the grid cells are county or precinct outlines that works even better, but this isn't a pie chart because a pie chart uses a polar coordinate system.
2) if you really must have a pie chart which is polar, consider that the average viewer may not be able to visually integrate the areas to get meaningful results. Further you will have to integrate the area swept out by the sectors of the pie like a radar screen, and this contour integration is made more difficult by the fact that you must do it numerically. This means you must sample the boundary distance as a function of angular displacement from some center of gravity you have chosen, like the state capitol. But depending on the location of the state capitol, your visual could become even more distorted. Idaho comes to mind.
3) a good compromise might be just to overlay a pie chart on top of a silhouette or map outline of the state with appropriate drop shadows and emphasis to make the pie chart pop as well as the state outline. it would certainly be much quicker as well as much more readable.

multiple stacked area charts nvd3 - errors

I am trying to create a dashboard with multiple area charts on the same page. I have two issues.
I want to get rid of the small circle on the chart that indicates value point and moves along with the cursor and the interactiveguideline. What is the name of that circle and how do I remove it?
After some research, I figured out how to change the Y-axis values to percentages. But I would like some graphs to show percentages and others to show regular numbers. Is there an easy way to do this?

D3 Stacked Bar Chart outer padding

I've been working on adapting the stacked bar chart example (http://bl.ocks.org/mbostock/1134768). The problem I'm having is that there's
always outerpadding. The API lists the outer padding as a 3rd option, but omitting
it or setting it to 0 still leaves some padding. In most cases, it isn't too bad,
but with large data sets it tends to be a huge amount of padding. For all the code
relevant to my issue, you can check the link above. It's not very noticeable in that
example, but the first bar isn't drawn until about 12 pixels (in larger data sets I'm using
this can be at 100 or more pixels); I want it to start at 0 pixels.
Thanks! If you need any more explanation just let me know and I'll do my best.
EDIT: After testing, it appears rangeBands() starts at 0, but I'm still not sure why the rounding
from round bands would round as much as it did. Oh well, I can deal with using rangeBands.